This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] malloc/obstack: Merge obstack code back from gnulib


On Fri, 28 Mar 2014, Paul Eggert wrote:

> On 03/28/2014 03:53 AM, Will Newton wrote:
> > The only change made was to replace _Noreturn with __attribute__
> > ((__noreturn__)).
> 
> It's better to keep the sources identical when possible.  Gnulib uses
> _Noreturn with the C11 meaning, and libc should move in that direction too.
> Attached is a revised patch to get the ball rolling on that.

I don't think we should #define _Noreturn in the case of GCC >= 4.7, when 
it's supported by GCC inside and outside C11 mode.

If we move to using _Noreturn (directly or indirectly via some other 
macro) in installed headers - logically right for supporting generic C11 
compilers, although I don't think many people are likely to be using the 
headers with compilers that don't define __GNUC__ - then there are the 
issues described in 
<https://sourceware.org/ml/libc-alpha/2012-01/msg00084.html> with where it 
can be placed in header declarations without either breaking use of the 
headers with GCC 2.7 or causing such use to lose the information that 
functions don't return.

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]