https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63326
Manuel López-Ibáñez <manu at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED Last reconfirmed| |2014-09-24 CC| |manu at gcc dot gnu.org Resolution|INVALID |--- Ever confirmed|0 |1 --- Comment #3 from Manuel López-Ibáñez <manu at gcc dot gnu.org> --- If you use #pragma GCC system_header, you get a different result, so this seems a bug to me (whatever the behavior, it should not depend on the type of #pragma). At the very least, GCC could give a warning if the #pragma is the only statement in a if/else/while/do/for body, since this is probably a bug.