From f121b9302e2531e42565e49fafaf3d3f487422cc Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Mon, 20 May 2013 22:50:41 +0000 Subject: PR14606: Debug Info for namespace aliases/DW_TAG_imported_module This resolves the last of the PR14606 failures in the GDB 7.5 test suite. (but there are still unresolved issues in the imported_decl case - we need to implement optional/lazy decls for functions & variables like we already do for types) llvm-svn: 182329 --- clang/lib/CodeGen/CodeGenModule.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'clang/lib/CodeGen/CodeGenModule.cpp') diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index 3a967c6..e651288 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -2879,10 +2879,13 @@ void CodeGenModule::EmitTopLevelDecl(Decl *D) { case Decl::ClassTemplate: case Decl::FunctionTemplate: case Decl::TypeAliasTemplate: - case Decl::NamespaceAlias: case Decl::Block: case Decl::Empty: break; + case Decl::NamespaceAlias: + if (CGDebugInfo *DI = getModuleDebugInfo()) + DI->EmitNamespaceAlias(cast(*D)); + return; case Decl::UsingDirective: // using namespace X; [C++] if (CGDebugInfo *DI = getModuleDebugInfo()) DI->EmitUsingDirective(cast(*D)); -- cgit v1.1