Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 14 Nov 2014 07:17:38 +0000
From:      "Poul-Henning Kamp" <phk@phk.freebsd.dk>
To:        Bruce Evans <brde@optusnet.com.au>
Cc:        svn-src-head@freebsd.org, =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= <des@des.no>, svn-src-all@freebsd.org, "Bjoern A. Zeeb" <bz@freebsd.org>, src-committers@freebsd.org
Subject:   Re: svn commit: r274340 - in head/sys: crypto/rijndael dev/random geom/bde
Message-ID:  <30932.1415949458@critter.freebsd.dk>
In-Reply-To: <20141114131512.C1552@besplex.bde.org>
References:  <201411100944.sAA9icnN061962@svn.freebsd.org> <3C962D07-3AAF-42EA-9D3E-D8F6D9A812B0@FreeBSD.org> <86sihq5a2v.fsf@nine.des.no> <20141111223756.F3519@besplex.bde.org> <86oasd6dad.fsf@nine.des.no> <20141112100207.Q1068@besplex.bde.org> <86h9y44fkp.fsf@nine.des.no> <20141114131512.C1552@besplex.bde.org>

next in thread | previous in thread | raw e-mail | index | archive | help
--------
In message <20141114131512.C1552@besplex.bde.org>, Bruce Evans writes:

>I also doing like the error for:
>
>int
>foo(bar_t b)
>{
> 	if (b < 0)
> 		return (EINVAL);
> 	...
>}
>
>where bar_t happens to an unsigned type so the error checking is null.
>The compiler warns, and the "fix" is to make the code less robust by
>removing the error checking.

+1

The -W-competition between CLANG and GCC has run off the rails.

The basic goal seems to emit as many warnings more than the competitor
as possible, since this "proves" that your compiler is better.

Before long I fear one of the them will introduce .w files where
one can explain details like the above on pseudo-language and the
other magic comments so one can add //!warn "blablabla" comments.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk@FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?30932.1415949458>