visual c++ - qualified names in C++ class declaration -


according this page, class name can "optionally qualified". thus, expect following code compile:

struct ::globalst {}; 

in msvc 2013u4, error:

error 1 error c2039: 'globalst' : not member of '`global namespace''

am misinterpreting reference or msvc bug?

if define class qualified name, name must have been declared. [class]/11

if class-head-name contains nested-name-specifier, class-specifier shall refer class declared directly in class or namespace nested-name-specifier refers, or in element of inline namespace set (7.3.1) of namespace (i.e., not merely inherited or introduced using-declaration), , class-specifier shall appear in namespace enclosing previous declaration. in such cases, nested-name-specifier of class-head-name of definition shall not begin decltype-specifier.


Comments

Popular posts from this blog

jquery - How do you format the date used in the popover widget title of FullCalendar? -

asp.net mvc - SSO between MVCForum and Umbraco7 -

Python Tkinter keyboard using bind -