bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 01/19] * m4/gnulib-common.m4 (gl_COMMON_BODY): Add _Noreturn.


From: Ben Pfaff
Subject: Re: [PATCH 01/19] * m4/gnulib-common.m4 (gl_COMMON_BODY): Add _Noreturn.
Date: Mon, 11 Jul 2011 15:42:36 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Bruno Haible <address@hidden> writes:

> In summary, it looks to me that the ISO C and ISO C++ committees need to
> do some more work to align the syntaxes.
>   extern noreturn void _Exit (void);
> vs.
>   extern [[noreturn]] void _Exit (void);

If the difference is this small, then we could work around it in
Gnulib:

#if (C++ style noreturn)
#define noreturn [[noreturn]]
#elif (C style noreturn)
/* nothing to do */
#elif (Microsoft style noreturn)
#define noreturn __declspec(noreturn)
#else
#define noreturn
#endif
-- 
Ben Pfaff 
http://benpfaff.org



reply via email to

[Prev in Thread] Current Thread [Next in Thread]