This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/53920] "gcc -E" does not honor #pragma GCC diagnostic ignored "-Wunused-macro"
- From: "naesten at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 10 Jul 2012 19:07:26 +0000
- Subject: [Bug preprocessor/53920] "gcc -E" does not honor #pragma GCC diagnostic ignored "-Wunused-macro"
- Auto-submitted: auto-generated
- References: <bug-53920-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53920
--- Comment #1 from Samuel Bronson <naesten at gmail dot com> 2012-07-10 19:07:26 UTC ---
Oh, I suppose I should mention that I ran into this because I was using ccache
to compile Emacs with --enable-gcc-warnings, and by default ccache runs the
preprocessor and the compiler in separate passes (so that it can skip the
compilation proper if it has cached output for a given preprocessor output),
and then pastes together the diagnostic output from the two passes.
(Thankfully, setting the environment variable CCACHE_CPP2 causes ccache to
throw out the preprocessor output after hashing, which is a quite effective
workaround for this sort of thing, though preprocessing the source twice does
make things a bit slower on cache misses.)