[PATCH] Correct __GNUC_PREREQ for __const__ and __noreturn__ attributes.
Joseph Myers
joseph@codesourcery.com
Wed Mar 22 17:32:00 GMT 2017
On Tue, 21 Mar 2017, Paul Eggert wrote:
> For what it's worth, Gnulib code uses __attribute__ ((__noreturn__)) for GCC
> 2.8 and later, and __attribute__ ((__const__)) for GCC 2.95 and later. I
> vaguely recall problems using these attributes in earlier GCC versions, though
> I'm afraid I don't remember the details. Perhaps Glibc wouldn't run into the
> problems, whatever they were.
I think the 2.8 conditional may be in order to support it at the start of
a function declaration (before the return type), i.e. compatibly with
_Noreturn.
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Libc-alpha
mailing list