This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: Fix name clash for ! __STDC__
- To: Alan Modra <alan at linuxcare dot com dot au>
- Subject: Re: Fix name clash for ! __STDC__
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Sat, 03 Jun 2000 20:27:25 +1000
- CC: Nick Clifton <nickc at cygnus dot com>, binutils at sourceware dot cygnus dot com
- Organization: Cygnus Solutions
- References: <Pine.LNX.4.21.0006031049420.22936-100000@front.linuxcare.com.au>
Alan Modra wrote:
>
> On Fri, 2 Jun 2000, Nick Clifton wrote:
>
> > : #ifdef __STDC__
> > : #define START_RELOC_NUMBERS(name) enum name { _##name = -1
> > : #else
> > : -#define START_RELOC_NUMBERS(name) enum name { name = -1
> > : +#define START_RELOC_NUMBERS(name) enum name { _/**/name = -1
> > : #endif
> >
> > Is this guarnateed to work with old K&R compilers ?
>
> Well, the /**/ trick is the pre-ansi standard way to paste tokens. Hmm,
> grepping through the source finds a number of such occurrences,
> eg. include/symcat.h and bfd/bfd-in.h. I'll use "|| defined(ALMOST_STDC)"
> as these files do.
Should the code use include/symcat.h?
(since you're stuck in K&R land :-)
Andrew