https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71613
Manuel López-Ibáñez <manu at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2016-06-21 CC| |manu at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #1 from Manuel López-Ibáñez <manu at gcc dot gnu.org> --- I think this is the same issue as for NULL (see Locations here: https://gcc.gnu.org/wiki/DiagnosticsGuidelines), however, we cannot keep track of all NULL-like macros defined in system-headers, can we? Perhaps a better work-around is to follow Clang, and give the warning at the location of the label plus highlighting the values: test.c:3:10: warning: ISO C restricts enumerator values to range of 'int' (-3000000000 is too small) [-Wpedantic] enum { c = -3000000000 }; ^ ~~~~~~~~~~~ That would completely avoid the problem.