summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2011-10-12 18:39:35 +0000
committerEric Christopher <echristo@apple.com>2011-10-12 18:39:35 +0000
commit93663b3c6226fb039aff10cc2edc3df51bf6bc23 (patch)
treea896daa2415cd71dc86e7f61df16b8ec2790475a /clang/lib/CodeGen/CodeGenModule.cpp
parent3d68aa838be45dc2bda53c9abd0089c41a177b5f (diff)
downloadbcm5719-llvm-93663b3c6226fb039aff10cc2edc3df51bf6bc23.tar.gz
bcm5719-llvm-93663b3c6226fb039aff10cc2edc3df51bf6bc23.zip
Revert file/scope handling patches. gdb testing revealed a couple of bugs.
llvm-svn: 141796
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 924ec8448e8..aab513fdce7 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -1392,8 +1392,10 @@ void CodeGenModule::EmitGlobalVarDefinition(const VarDecl *D) {
EmitCXXGlobalVarDeclInitFunc(D, GV);
// Emit global variable debug information.
- if (CGDebugInfo *DI = getModuleDebugInfo())
+ if (CGDebugInfo *DI = getModuleDebugInfo()) {
+ DI->setLocation(D->getLocation());
DI->EmitGlobalVariable(GV, D);
+ }
}
llvm::GlobalValue::LinkageTypes
OpenPOWER on IntegriCloud