More improvements to namespace aliases. We now support everything except aliases in using directives.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67966 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/SemaCXX/namespace-alias.cpp b/test/SemaCXX/namespace-alias.cpp
index 87e8b2c..c715c9f 100644
--- a/test/SemaCXX/namespace-alias.cpp
+++ b/test/SemaCXX/namespace-alias.cpp
@@ -25,3 +25,26 @@
 namespace G { 
   namespace B = N;
 }
+
+namespace H {
+  namespace A1 { }
+  namespace A2 { }
+
+  // These all point to A1.
+  namespace B = A1; // expected-note {{previous definition is here}}
+  namespace B = A1;
+  namespace C = B;
+  namespace B = C;
+
+  namespace B = A2; // expected-error {{redefinition of 'B' as different kind of symbol}}
+}
+
+namespace I { 
+  namespace A1 { int i; }
+  
+  namespace A2 = A1;
+}
+
+int f() {
+  return I::A2::i;
+}