summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
diff options
context:
space:
mode:
authorManman Ren <mren@apple.com>2013-01-04 18:51:35 +0000
committerManman Ren <mren@apple.com>2013-01-04 18:51:35 +0000
commitab08a9adab8e7b4bcdd25b7b425e06128bb33b69 (patch)
tree59a3699eeb4033cbb633691cdd10ff141fd68c8a /clang/lib/CodeGen
parentcb6c867c46bf791dbce641b6cd83571178137926 (diff)
downloadbcm5719-llvm-ab08a9adab8e7b4bcdd25b7b425e06128bb33b69.tar.gz
bcm5719-llvm-ab08a9adab8e7b4bcdd25b7b425e06128bb33b69.zip
Debug Info: fix the line location for cleanup code of a block function
The line information was changed when emitting debug information for all the DeclRefExprs and we should change it back to get ready for PopClenupBlocks called from FinishFunction. rdar://11562117 llvm-svn: 171493
Diffstat (limited to 'clang/lib/CodeGen')
-rw-r--r--clang/lib/CodeGen/CGBlocks.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CGBlocks.cpp b/clang/lib/CodeGen/CGBlocks.cpp
index 68958522d8f..54bcb88ce38 100644
--- a/clang/lib/CodeGen/CGBlocks.cpp
+++ b/clang/lib/CodeGen/CGBlocks.cpp
@@ -1176,6 +1176,9 @@ CodeGenFunction::GenerateBlockFunction(GlobalDecl GD,
Builder, blockInfo);
}
}
+ // Recover location if it was changed in the above loop.
+ DI->EmitLocation(Builder,
+ cast<CompoundStmt>(blockDecl->getBody())->getRBracLoc());
}
// And resume where we left off.
OpenPOWER on IntegriCloud