From 2fd5a0f3eafe65c73b737a1cd995dfda7302ed81 Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Fri, 3 Jun 2011 17:05:26 +0000 Subject: [PATCH] Fix typedef's context. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132557 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CGDebugInfo.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/CodeGen/CGDebugInfo.cpp b/lib/CodeGen/CGDebugInfo.cpp index cc0dbd6bb5..7f81d30c67 100644 --- a/lib/CodeGen/CGDebugInfo.cpp +++ b/lib/CodeGen/CGDebugInfo.cpp @@ -555,8 +555,9 @@ llvm::DIType CGDebugInfo::CreateType(const TypedefType *Ty, // We don't set size information, but do specify where the typedef was // declared. unsigned Line = getLineNumber(Ty->getDecl()->getLocation()); - llvm::DIType DbgTy = DBuilder.createTypedef(Src, Ty->getDecl()->getName(), - Unit, Line); + llvm::DIType DbgTy = + DBuilder.createTypedef(Src, Ty->getDecl()->getName(), Unit, Line, + getContextDescriptor(cast(Ty->getDecl()->getDeclContext()))); return DbgTy; } -- 2.50.1