diff options
Diffstat (limited to 'test/SemaCXX/member-expr.cpp')
-rw-r--r-- | test/SemaCXX/member-expr.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/test/SemaCXX/member-expr.cpp b/test/SemaCXX/member-expr.cpp index cd13bcc..9cd6855 100644 --- a/test/SemaCXX/member-expr.cpp +++ b/test/SemaCXX/member-expr.cpp @@ -41,3 +41,18 @@ void test2(X *xp) { xp->::i = 7; // expected-error{{qualified member access refers to a member in the global namespace}} xp->C::i = 7; // expected-error{{qualified member access refers to a member in namespace 'C'}} } + + +namespace test3 { + struct NamespaceDecl; + + struct NamedDecl { + void *getIdentifier() const; + }; + + struct NamespaceDecl : NamedDecl { + bool isAnonymousNamespace() const { + return !getIdentifier(); + } + }; +} |