summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/NestedNameSpecifier.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/AST/NestedNameSpecifier.cpp')
-rw-r--r--clang/lib/AST/NestedNameSpecifier.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/AST/NestedNameSpecifier.cpp b/clang/lib/AST/NestedNameSpecifier.cpp
index 1ff2e7177b3..858cf12dc66 100644
--- a/clang/lib/AST/NestedNameSpecifier.cpp
+++ b/clang/lib/AST/NestedNameSpecifier.cpp
@@ -229,6 +229,9 @@ NestedNameSpecifier::print(raw_ostream &OS,
break;
case Namespace:
+ if (getAsNamespace()->isAnonymousNamespace())
+ return;
+
OS << getAsNamespace()->getName();
break;
OpenPOWER on IntegriCloud