Bug 29514 - A member variable named 'not' is intrepreted by the compiler as the '!' sign.
Summary: A member variable named 'not' is intrepreted by the compiler as the '!' sign.
Status: RESOLVED INVALID
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 4.0.2
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-10-19 10:03 UTC by Sela Lerer
Modified: 2006-10-19 10:26 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments
Source file for the code that created the bug. (36 bytes, text/plain)
2006-10-19 10:05 UTC, Sela Lerer
Details
The *.ii file created by the compiler from the source file. (79 bytes, application/octet-stream)
2006-10-19 10:06 UTC, Sela Lerer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sela Lerer 2006-10-19 10:03:50 UTC
Look at the source file first, its very short.

$ g++ -c -save-temps main.cpp
main.cpp:4: error: expected unqualified-id before ‘!’ token

$ g++ --version
g++ (GCC) 4.0.2 20051125 (Red Hat 4.0.2-8)
Copyright (C) 2005 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$ cat /proc/version
Linux version 2.6.17-1.2142_FC4smp (bhcompile@hs20-bc1-4.build.redhat.com) (gcc version 4.0.2 20051125 (Red Hat 4.0.2-8)) #1 SMP Tue Jul 11 22:57:02 EDT 2006
Comment 1 Sela Lerer 2006-10-19 10:05:19 UTC
Created attachment 12459 [details]
Source file for the code that created the bug.
Comment 2 Sela Lerer 2006-10-19 10:06:12 UTC
Created attachment 12460 [details]
The  *.ii   file created by the compiler from the source file.
Comment 3 Paolo Carlini 2006-10-19 10:26:06 UTC
not a bug: per section 2.5 of the Standard 'not' is an alternative token for '!'