]> granicus.if.org Git - clang/commitdiff
Print the qualified name when dumping deserialized decls.
authorVassil Vassilev <v.g.vassilev@gmail.com>
Sun, 20 May 2018 09:38:52 +0000 (09:38 +0000)
committerVassil Vassilev <v.g.vassilev@gmail.com>
Sun, 20 May 2018 09:38:52 +0000 (09:38 +0000)
This is useful to understand and debug the lazy template specializations
used in the pch and modules.

Differential Revision: https://reviews.llvm.org/D41785

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@332817 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Frontend/FrontendAction.cpp

index 122dc23388ccd9e951009c36e69d28b9bec42c65..7711d8460c5a7a95df4048d1dce75c0d36040376 100644 (file)
@@ -88,8 +88,10 @@ public:
 
   void DeclRead(serialization::DeclID ID, const Decl *D) override {
     llvm::outs() << "PCH DECL: " << D->getDeclKindName();
-    if (const NamedDecl *ND = dyn_cast<NamedDecl>(D))
-      llvm::outs() << " - " << *ND;
+    if (const NamedDecl *ND = dyn_cast<NamedDecl>(D)) {
+      llvm::outs() << " - ";
+      ND->printQualifiedName(llvm::outs());
+    }
     llvm::outs() << "\n";
 
     DelegatingDeserializationListener::DeclRead(ID, D);