Email List: Xaustin-group-lX
[All Lists]

Re: c99 -I option and GCC

To: austin-group-l@xxxxxxxxxxxxx
Subject: Re: c99 -I option and GCC
From: Geoff Clare <gwc@xxxxxxxxxxxxx>
Date: Tue, 4 Aug 2009 09:33:11 +0100
References: <4a76fb43.lbC4QjMxLz0GOnAz%Joerg.Schilling@fokus.fraunhofer.de> <200908031526.n73FQ0M7002876@aragorn.savarese.org> <20090804003819.GE3746@prunille.vinc17.org>
Vincent Lefevre <vincent-opgr@vinc17.org> wrote, on 04 Aug 2009:
>
> What's the behavior if one gives several -D options with the same name
> and different values (and no corresponding -U option)?

A diagnostic message must be written.  This is because the description
of -D says it defines the named macro "as if by a C-language #define
directive", and C99 requires a diagnostic if there are multiple
#define directives for the same name with different values (or more
specifically, where the preprocessing tokens in the values do not
have "the same number, ordering, spelling, and white-space separation,
where all white-space separations are considered identical").

-- 
Geoff Clare <g.clare@opengroup.org>
The Open Group, Thames Tower, Station Road, Reading, RG1 1LX, England

<Prev in Thread] Current Thread [Next in Thread>