aboutsummaryrefslogtreecommitdiff
path: root/test/SemaCXX/enum-scoped.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaCXX/enum-scoped.cpp')
-rw-r--r--test/SemaCXX/enum-scoped.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/test/SemaCXX/enum-scoped.cpp b/test/SemaCXX/enum-scoped.cpp
index 2c3537e163..73e7578ecb 100644
--- a/test/SemaCXX/enum-scoped.cpp
+++ b/test/SemaCXX/enum-scoped.cpp
@@ -120,7 +120,7 @@ namespace rdar9366066 {
}
}
-// Part of PR10264
+// Part 1 of PR10264
namespace test5 {
namespace ns {
typedef unsigned Atype;
@@ -130,3 +130,15 @@ namespace test5 {
x, y, z
};
}
+
+// Part 2 of PR10264
+namespace test6 {
+ enum A : unsigned;
+ struct A::a; // expected-error {{incomplete type 'test6::A' named in nested name specifier}}
+ enum A::b; // expected-error {{incomplete type 'test6::A' named in nested name specifier}}
+ int A::c; // expected-error {{incomplete type 'test6::A' named in nested name specifier}}
+ void A::d(); // expected-error {{incomplete type 'test6::A' named in nested name specifier}}
+ void test() {
+ (void) A::e; // expected-error {{incomplete type 'test6::A' named in nested name specifier}}
+ }
+}