From: | glen herrmannsfeldt <gah@ugcs.caltech.edu> |
Newsgroups: | comp.compilers |
Date: | Sun, 12 Feb 2012 06:29:16 +0000 (UTC) |
Organization: | Aioe.org NNTP Server |
References: | 12-02-004 12-02-006 12-02-009 12-02-013 |
Keywords: | parse, C++, debug |
Posted-Date: | 12 Feb 2012 01:31:55 EST |
Steven G. Kargl <sgk@removetroutmask.apl.washington.edu> wrote:
> In file included from actions.cpp:4,
> from dfac.cpp:2:
> global.h:52:15: error: "or" cannot be used as a macro name as
> it is an operator in C++
In C, the preprocessor is logically before the compiler, so, as far as
I understand, there is no problem using any C reserved word as a macro
name, as long as you don't need the word.
I know C++ isn't C, but this one surprises me.
Still, if you aren't using the "or" operator, a quick pass through sed
should be able to fix it.
-- glen
Return to the
comp.compilers page.
Search the
comp.compilers archives again.