On Wed, 13 Mar 2019, Jakub Jelinek wrote: > Hi! > > The C FE sadly passes through some really bad prototypes of builtin > functions as "harmless": > /* Accept "harmless" mismatches in function types such > as missing qualifiers or pointer vs same size integer > mismatches. This is for the ffs and fprintf builtins. > However, with -Wextra in effect, diagnose return and > argument types that are incompatible according to > language rules. */
Note that this isn't just about pre-standard headers with unexpected types (if it were, it might be obsolete). It's also needed for building glibc (to build glibc with -Wextra with GCC trunk, one of the -Wno- options needed is -Wno-builtin-declaration-mismatch), because of how various code creates function aliases between functions that have the same ABI but different types (long versus int, etc.). -- Joseph S. Myers jos...@codesourcery.com