c++/10729: BUG on illegal code - namespace name clash(?)

thomr9am@ss1000.ms.mff.cuni.cz thomr9am@ss1000.ms.mff.cuni.cz
Sat May 10 11:39:00 GMT 2003


>Number:         10729
>Category:       c++
>Synopsis:       BUG on illegal code - namespace name clash(?)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat May 10 10:26:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Rudo Thomas
>Release:        gcc version 3.2.3
>Organization:
>Environment:
GNU/Linux, gcc built from scratch
>Description:
GCC suggested I submitted a bug report when trying to compile the following code:

namespace A { const int i = 1; }
class A { const int i; };
::A:i = 2;

The error message is:
bug.cc:3: `A' as declarator

It is worth mentioning that the code is completely ill-formed ;-)
>How-To-Repeat:
Copy and paste the 3 lines of code from description above to, say, bug.cc . Run gcc bug.cc .
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the Gcc-bugs mailing list