This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: Wno-warning-directives [WasRe: cpplib: Start moving ...]
- From: Zack Weinberg <zack at codesourcery dot com>
- To: Mark Mitchell <mark at codesourcery dot com>
- Cc: Stan Shebs <shebs at apple dot com>, Geoff Keating <geoffk at geoffk dot org>,Devang Patel <dpatel at apple dot com>,"gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 26 Aug 2002 00:39:08 -0700
- Subject: Re: PATCH: Wno-warning-directives [WasRe: cpplib: Start moving ...]
- References: <3D585ACE.6050705@apple.com> <12930000.1029255569@warlock.codesourcery.com>
On Tue, Aug 13, 2002 at 09:19:29AM -0700, Mark Mitchell wrote:
> If the consensus turns out to be that we should ignore #warning in
> system headers (contrary to my opinion, but I've been in the minority
> plenty of times before!) then we should just make that the unconditional
> behavior.
>
> (There is, by the way, probably already a workaround: use explicit -I
> directives to find these headers as ordinary headers, not as system
> headers. Not to mention fixincludes, which is what we usually use for
> OS headers that are unusable with GCC.)
Not to rain on your parade, but we just checked in a patch that makes
your suggested workaround not work anymore (the this-time-for-sure fix
for those annoying 'changing search order' warnings).
While in general I agree with you that we have too many options, I
think that additional warning-control options are not nearly as
problematic as others, since they are usually simple to implement,
easy to document, have narrowly defined semantics, and do not affect
code generation at all (modulo bugs). As long as we don't have a
general mechanism for disabling individual warnings, I'm inclined to
accede to requests for more finegrained -W options.
zw