This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/15519] New: preprocessor mistreats backslash-blank-newline in // comment
- From: "doug at cs dot dartmouth dot edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 May 2004 15:33:25 -0000
- Subject: [Bug c++/15519] New: preprocessor mistreats backslash-blank-newline in // comment
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
In both 3.3.1 (cygwin, NT) and 3.2.2 (redhat, linux) the preprocessor
silently--and wrongly--eats the declaration below, where $ marks
have been placed to show the end of lines. The comment was carefully
written to avoid the very misbehavior that it elicited.
To exhibit the trouble, remove the $ marks and compile with
g++ -pedantic -E
// boolean operation /\ $
extern int band(int,int);$
In some contexts g++ warns of the presence of backslash-space-newline,
but not in comments. Under option -Wall, it reports a "multiline
comment". The warnings do not, however, point out that the g++
interpretation is nonstandard, even in -pedantic mode.
--
Summary: preprocessor mistreats backslash-blank-newline in //
comment
Product: gcc
Version: 3.3.1
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: doug at cs dot dartmouth dot edu
CC: gcc-bugs at gcc dot gnu dot org
GCC host triplet: I can't guess what a "triplet" is
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15519