[PATCH] argp: Do not override GCC keywords with macros [BZ #16907]

Florian Weimer fweimer@redhat.com
Mon Aug 15 20:16:00 GMT 2016


On 08/15/2016 09:50 PM, Carlos O'Donell wrote:
> On 08/14/2016 03:01 PM, Florian Weimer wrote:
>> glibc provides fallback definitions already.  It is not necessary to
>> suppress warnings for unknown attributes because GCC does this
>> automatically for system headers.
>
> Does gcc do this for all known versions that we support compiling
> applications with?
>
> We support compiling applications with new glibc headers, but old
> gcc, and we shouldn't break that, though we need not optimize for it.
>
> https://sourceware.org/ml/libc-alpha/2015-05/msg00526.html

With GCC 2.7.2.3, an unknown attribute is just a warning, not a hard 
error.  It is not suppressed in system headers, though.  <sys/types.h> 
already produces a warning:

/usr/include/bits/pthreadtypes.h:123: warning: unnamed struct/union that 
defines no instances

And no one has complained.

I can go back further if absolutely necessary.

Florian



More information about the Libc-alpha mailing list