preprocessor, 'inline', and Apple's gcc

David Monniaux David.Monniaux at
Wed Mar 19 16:37:04 CET 2008

Torbjorn Granlund wrote:
> I take it that there are no problems unless you force the use of the
> -std=c99 option?
This is correct. APRON uses -std=c99
> Why don't we ignore __GNU_STDC_INLINE__ and make decision solely on
> __STDC_VERSION__ (when __GNUC__ is defined)?  That ought to simplify
> the logics.
When __GNUC__ is defined, we're either on gcc, either on patched 
versions of gcc including Apple's, or even on compilers claiming to 
behave like gcc (I think Intel's cc defines __GNUC__).

For a while, gcc had a -std=c99 mode that did not turn on C99-compatible 
semantics for 'inline', yet defined  __STDC_VERSION__ to be 199901L- 
this is the case for gcc 4.1.2.

Are there any compilers out there, save for gcc, who both have 
non-standard semantics for inline yet define __STDC_VERSION__ to be 199901L?

Point taken about #elif, though I wonder whether this is the only part 
of GMP that would not go through a K&R compiler - I don't even know 
where to find a system with a K&R compiler...
-------------- next part --------------
A non-text attachment was scrubbed...
Name: David.Monniaux.vcf
Type: text/x-vcard
Size: 383 bytes
Desc: not available
Url : 

More information about the gmp-devel mailing list