Still having major problems with cpplib and imake
Jakub Jelinek
jakub@redhat.com
Fri May 12 02:44:00 GMT 2000
On Fri, May 12, 2000 at 06:34:28PM +0900, Neil Booth wrote:
> Jakub Jelinek wrote:-
>
> > > OK - I was afraid it would involve storing copies of arbitrary
> > > whitespace. I agree something should be workable if the only problem
> > > is tabs first on a line.
> >
> > Yes, I believe so, unless you want to kill -traditional, which would mean
> > rewriting quite a lot of macros in config/cf because they expect K&R cpp (e.g.
> > stuff like
> > #define SomeMacro(lib) SomeOtherMacro(lib.a)
> > is all over the place.
> > Although config/cf has a few macros written for both K&R and ANSI, most of
> > the macros are not.
>
> Sorry, Jakub, I don't quite understand. Are you saying an initial tab
> is the only case we need to get right?
Yes, I wanted to say initial tab is the only problematic case with
-traditional I saw at the moment (once that is fixed, I can try once again
and throw the generated Makefiles to make and try to compile X to see if
other things aren't broken as well).
>
> I don't understand your example, either. Doesn't that work for any
> preprocessor, regardless of -traditional?
Look below, X11 contains a lot of B-style macros, while it should use
C-style macros to work with both K&R and ANSI. X expects lib.a, space in
between is for obvious reason wrong (it is a filename).
#if (__STDC__ && !defined(UnixCpp)) || defined(AnsiCpp)
#define Concat(a,b)a##b
#else
#define Concat(a,b)a/**/b
#endif
#define A(x) x
#define B(y) A(y.a)
#define C(y) A(Concat(y,.a))
B(lib)
C(lib)
Jakub
More information about the Gcc-bugs
mailing list