preprocessor/3786: cpp ignores space after backslash

Joseph S. Myers jsm28@cam.ac.uk
Tue Jul 24 02:34:00 GMT 2001


On Tue, 24 Jul 2001 loewis@informatik.hu-berlin.de wrote:

>   The preprocessor will ignore spaces between a backslash and a newline
>   for continuation lines. This is in violation of C99, 5.1.1.2,
>   # Each instance of a backslash character (\) immediately followed 
>   # by a new-line character is deleted
>   As a result, a // comment ending in a backslash eats the next line.

This is part of the implementation-defined translation phase 1 mapping:
invisible white space at the end of lines is ignored.  There *is* a bug -
that this feature ought to be mentioned under "Implementation-defined
behavior" in the manual.

-- 
Joseph S. Myers
jsm28@cam.ac.uk



More information about the Gcc-bugs mailing list