This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
egcs-1.1/Solaris: warnings in system headers with -Wall
- To: egcs at cygnus dot com
- Subject: egcs-1.1/Solaris: warnings in system headers with -Wall
- From: papadopo at shfj dot cea dot fr (Dimitri PAPADOPOULOS-ORFANOS)
- Date: Fri, 4 Sep 1998 16:08:27 +0200
Using egcs-1.1 with -Wall under Solaris 2.5.1, I get warnings inside
system file, like:
/usr/openwin/include/X11/Xutil.h:843: warning: return-type of `XUnionRegion' defaults to `int'
in function
extern XUnionRegion(
#if NeedFunctionPrototypes
Region /* sra */,
Region /* srb */,
Region /* dr_return */
#endif
);
/usr/openwin/include/GL/glu.h:2: warning: ignoring pragma: ignored
in line
#pragma ident "@(#)glu.h 1.6 97/05/05 SMI"
Of course, these headers do contain errors (like many Sun
headers), but I have old sources that compiled without warnings
up to egcs-1.0.3a, and I don't want to change all the Makefiles.
Have more warnings been added to -Wall?
I only found the following changes documented:
+ New warning -Wno-pmf-conversion (don't warn about
converting from a bound member function pointer to function
pointer).
+ A flag -Weffc++ has been added for violations of some of the style
guidelines in Scott Meyers' _Effective C++_ books.
+ -Woverloaded-virtual now warns if a virtual function in a base
class is hidden in a derived class, rather than warning about
virtual functions being overloaded (even if all of the inherited
signatures are overridden) as it did before.
+ -Wall no longer implies -W. The new warning flag, -Wsign-compare,
included in -Wall, warns about dangerous comparisons of signed and
unsigned values. Only the flag is new; it was previously part of
-W.
+ The new flag, -fno-weak, disables the use of weak symbols.