[Bug c++/50811] G++ rejects class-virt-specifier if class-head-name includes nested-name-specifier

ville.voutilainen at gmail dot com gcc-bugzilla@gcc.gnu.org
Thu Oct 20 23:27:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50811

--- Comment #1 from Ville Voutilainen <ville.voutilainen at gmail dot com> 2011-10-20 23:26:57 UTC ---
Oh my.

struct C
{
        int x;
};

int main()
{
        struct C final {};
        int y = final.x;
}

says 
error: ‘final’ was not declared in this scope

When it's just struct C final; it works fine.



More information about the Gcc-bugs mailing list