This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] New flag -Wsystem-headers
- To: gcc-patches at gcc dot gnu dot org, branko dot cibej at hermes dot si
- Subject: Re: [patch] New flag -Wsystem-headers
- From: Benjamin Kosnik <bkoz at redhat dot com>
- Date: Mon, 25 Sep 2000 15:40:07 -0700
This patch is now in.
Hopefully, this will make the shadow header work for libstdc++-v3 easier.
bootstrapped on x86/linux
Thanks Branko!
-benjamin
2000-09-25 Branko Cibej <branko.cibej@hermes.si>
* flags.h: Declare warning flag warn_system_headers.
* toplev.c: Define it.
(W_options): Add option -Wsystem-headers.
* diagnostic.c (count_error): Test warn_system_headers.
* invoke.texi: Add description for -Wsystem-headers.
* cpplib.h (cpp_options): New member warn_system_headers.
* cpphash.h (CPP_PEDANTIC, CPP_WTRADITIONAL): Don't test
CPP_IN_SYSTEM_HEADER.
* cpplib.c (do_import, do_pragma_once): Likewise.
* cpperror.c (_cpp_begin_message): Test warn_system_headers
and CPP_IN_SYSTEM_HEADER.
* cppinit.c (handle_option): Recognize -Wsystem_headers.
(print_help): Describe -Wsystem_headers.
* cpplex.c (lex_line): Reorganize condition so that warnings
about C++ comments in system headers can be enabled. Remove
label do_line_comment.