This is the mail archive of the
mailing list for the GCC project.
Re: Preventing ISO C errors when using macros for builtin types
- From: Segher Boessenkool <segher at kernel dot crashing dot org>
- To: Jozef Lawrynowicz <jozefl dot gcc at gmail dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Wed, 5 Jun 2019 11:49:21 -0500
- Subject: Re: Preventing ISO C errors when using macros for builtin types
- References: <20190605142559.05791323@jozef-kubuntu>
On Wed, Jun 05, 2019 at 02:25:59PM +0100, Jozef Lawrynowicz wrote:
> I'm assuming it would not be valid to modify the behaviour of __extension__
> so it can be placed within a declaration, and not just at the
> beginning. However, there is minimal documentation on this keyword (it does not
> state that it can be used in declarations, even though it can), so I wonder
> what the "rules" are.
The documentation says
'-pedantic' and other options cause warnings for many GNU C extensions.
You can prevent such warnings within one expression by writing
'__extension__' before the expression. '__extension__' has no effect
aside from this.
It's not clear to me why you cannot simply put __extension__ earlier in