This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Generally use underscore-pre-/-postfixed attributes?
- From: "Carlos O'Donell" <carlos at redhat dot com>
- To: Thomas Schwinge <thomas at codesourcery dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Wed, 20 Feb 2013 11:35:52 -0500
- Subject: Re: Generally use underscore-pre-/-postfixed attributes?
- References: <20130220155636.14583.qmail@sourceware.org> <871ucbar01.fsf@kepler.schwinge.homeip.net>
On 02/20/2013 11:29 AM, Thomas Schwinge wrote:
> Hi!
>
> On 20 Feb 2013 15:56:36 -0000, I wrote:
>> commit c7b275d6b3bceb6b400fa3044d13d1001bc605ca
>> Author: Thomas Schwinge <thomas@codesourcery.com>
>> Date: Tue Feb 19 13:06:39 2013 +0100
>>
>> bits/nan.h: Change __attribute_used__ to __attribute__ ((unused)).
>
> Joseph reminded me that __attribute__ ((unused)) is not appropriate; it
> needs to be __attribute__ ((__unused__)) in installed headers, as the
> former tampers with the user namespace.
>
> Should we perhaps generally use the underscore-pre-/-postfixed form of
> attributes in all of glibc's source files to not have to worry about
> installed/not installed headers? Or is that overkill?
No it is not overkill.
I love simple rules.
We should use double-underscore everywhere IMO.
The only argument against them is that they increase the size of the
headers and thus reduce compilation performance? Can anyone prove that? :-)
Cheers,
Carlos.