This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/62116] Allowing redeclaration of global variable x using ::x
- From: "richard-gccbugzilla at metafoo dot co.uk" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 19 Feb 2015 23:12:22 +0000
- Subject: [Bug c++/62116] Allowing redeclaration of global variable x using ::x
- Auto-submitted: auto-generated
- References: <bug-62116-4 at http dot gcc dot gnu dot org/bugzilla/>
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.