[Bug c++/71975] In c++11/14 mode enumname::name is assumed name to be part of the enumname

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sun Jul 24 04:32:00 GMT 2016


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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|In c++11/14 mode            |In c++11/14 mode
                   |whitespaces are ignored     |enumname::name is assumed
                   |between enum or class type  |name to be part of the
                   |name and ::                 |enumname

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
White space has nothing to do it with it really.

This is just a parsing issue.  Basically the C++ front-end assumes enu is a
type so ::wow will be a part of the scope.  I don't know what the C++ standard
says here either.

What happens if enu is a struct/class instead?


More information about the Gcc-bugs mailing list