https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61977

--- Comment #8 from David Rivshin <drivshin at allworx dot com> ---
I briefly tested the patch, and it does fix the ICE in the case where the
conditional macro is the last token.

However it does not fix the situation where there are more (non-blank) lines
after the conditional macro:

$ /bin/echo -e "; comment ending in vector\n; another comment" |
../local/bin/powerpc-eabi-cpp -x assembler-with-cpp
# 1 "<stdin>"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "<stdin>"
; comment ending in
 vector
# 2 "<stdin>"
; another comment

There is a newline which gets inserted in the stream before the conditional
macro token. In many cases that is harmless, but in some (like the above
single-line assembler comment) the result is to turn valid code into invalid
code.

Reply via email to