------- Comment #16 from manu at gcc dot gnu dot org 2008-08-18 13:55 ------- __extension__ now works for CPP warnings in the C front-end.
The issue with system headers is more difficult since it depends on having two locations. C++ lexes everything up front before parsing anything, so the warnings from CPP are all emitted before any C++ warning and __extension__ are handled. I don't see any easy fix to this (apart from moving pedantic CPP warnings to c-common.c but that won't be trivial). -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=7263