summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/nested-name-spec.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/SemaCXX/nested-name-spec.cpp')
-rw-r--r--clang/test/SemaCXX/nested-name-spec.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/nested-name-spec.cpp b/clang/test/SemaCXX/nested-name-spec.cpp
index 454af5ef196..4e65b41e666 100644
--- a/clang/test/SemaCXX/nested-name-spec.cpp
+++ b/clang/test/SemaCXX/nested-name-spec.cpp
@@ -207,3 +207,16 @@ namespace test1 {
}
};
}
+
+// We still need to do lookup in the lexical scope, even if we push a
+// non-lexical scope.
+namespace test2 {
+ namespace ns {
+ int *count_ptr;
+ }
+ namespace {
+ int count = 0;
+ }
+
+ int *ns::count_ptr = &count;
+}
OpenPOWER on IntegriCloud