This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Serious error-causing change in new CPP's -traditional behavior
On Tue, May 09, 2000 at 12:07:40PM +0100, Richard Earnshaw wrote:
> Sadly, I think -traditional will always be required for processing ARM
> assembler, unless cpp is fixed to not generate an error for the following
> case.
> '#' introduces an immediate constant in the assembler syntax; removing it
> is bogus, and worse, there is no way to escape it that I can see, other
> than by playing stupid games.
A marginally better stupid game:
#define IMMED(n) # ##n
#define foo() mov r0, IMMED(5)
.text
bar:
foo()
$ cpp test.S
.text
bar:
mov r0, #5
But it really should be just a warning, and the # should appear in the
output, and we could suppress the warning when processing .S files.
I'll see what I can do.
zw