Joy with new GCC 3.3 warnings -- HTF to shut them up?

David O'Brien obrien@FreeBSD.org
Fri May 2 15:45:00 GMT 2003


On Fri, May 02, 2003 at 05:31:47PM +0200, Gabriel Dos Reis wrote:
> | > -Wall has become de-facto standard, and one of my roles over the last
> | > decade or so has been to try to keep it that way (getting warnings taken
> | > out of -Wall if they can't be suppressed without either excessive pain
> | > or making the code worse).
> | 
> | It seems -Wall has also grown -Wsign-compare.  Much FreeBSD's /usr/src
> | that was GCC 3.2.2 -Wall -Werror clean now produce tons of:
> | 
> |     "warning: signed and unsigned type in conditional expression"
> | 
> | was it really the intention that -Wall grow so many new warnings?
> 
> I think BSD is being bitten by the fuzzy logic around -Wall.

That is true.
 
>   1) as its name does not suggest, it does not turn on all warnings;
> 
>   2) There is no well formed, clear stated, widely accepted criteria
>      to apply when considering a warning-switch as candidate for -Wall

One could say the accepted criteria for considering a warning-switch as
candidate for -Wall is "no".  That is, -Wall just warns about things it
has traditionally done so, and no new warning classes are added to it.
As mentioned above it is a multi-decade de-facto standard.



More information about the Gcc mailing list