This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/62116] Allowing redeclaration of global variable x using ::x


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

Richard Smith <richard-gccbugzilla at metafoo dot co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |richard-gccbugzilla@metafoo
                   |                            |.co.uk

--- Comment #3 from Richard Smith <richard-gccbugzilla at metafoo dot co.uk> ---
This is a GCC bug (or extension). Expression / declaration disambiguation is
purely syntactic, and 'int(::x);' conforms to the grammar for a
simple-declaration.

I've also reported the bug to EDG.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]