This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: rfc: macros accepting constructors
- From: Joern Rennecke <joern dot rennecke at superh dot com>
- To: Andreas Schwab <schwab at suse dot de>
- Cc: Aldy Hernandez <aldyh at redhat dot com>, jason at redhat dot com, gcc at gcc dot gnu dot org, geoffk at redhat dot com
- Date: Thu, 27 Jun 2002 17:22:54 +0100
- Subject: Re: rfc: macros accepting constructors
- Organization: SuperH UK Ltd.
>Aldy Hernandez <aldyh@redhat.com> writes:
>
>|> the cleanest solution i can think of is modifying the preprocessor to
>|> allow grouping with curlies as well.
Andreas Schwab:
>That would not be compliant with the C standard.
It would if that grouping is only enabled for macros that are
defined in a way that is non-standard or invokes implementation-defined
behaviour.
E.g. we could precede the macro definition with a
#pragma gcc initializer_argument ,
or have some funky syntax for the macro definition, like:
#define foo({x}) bar((x))
--
--------------------------
SuperH
2430 Aztec West / Almondsbury / BRISTOL / BS32 4AQ
T:+44 1454 462330