summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenFunction.cpp
diff options
context:
space:
mode:
authorAdrian Prantl <aprantl@apple.com>2013-05-16 00:41:26 +0000
committerAdrian Prantl <aprantl@apple.com>2013-05-16 00:41:26 +0000
commitdc237b52bc916c5156dcdadf143e73d97a5c0ccf (patch)
treeb4d160d1cfefa2d8d8ff2f4af20a4ff1f5b4233b /clang/lib/CodeGen/CodeGenFunction.cpp
parentff1596c2a16390e4680aec99ac733c811493e7aa (diff)
downloadbcm5719-llvm-dc237b52bc916c5156dcdadf143e73d97a5c0ccf.tar.gz
bcm5719-llvm-dc237b52bc916c5156dcdadf143e73d97a5c0ccf.zip
Cleanup: Use a member variable to store the SourceLocation for EH code.
rdar://problem/13888152 llvm-svn: 181957
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenFunction.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenFunction.cpp b/clang/lib/CodeGen/CodeGenFunction.cpp
index 071c08e6bf2..3e04ae7d153 100644
--- a/clang/lib/CodeGen/CodeGenFunction.cpp
+++ b/clang/lib/CodeGen/CodeGenFunction.cpp
@@ -209,7 +209,7 @@ void CodeGenFunction::FinishFunction(SourceLocation EndLoc) {
// edges will be *really* confused.
bool EmitRetDbgLoc = true;
if (EHStack.stable_begin() != PrologueCleanupDepth) {
- PopCleanupBlocks(PrologueCleanupDepth, EndLoc);
+ PopCleanupBlocks(PrologueCleanupDepth);
// Make sure the line table doesn't jump back into the body for
// the ret after it's been at EndLoc.
@@ -666,6 +666,7 @@ void CodeGenFunction::GenerateCode(GlobalDecl GD, llvm::Function *Fn,
SourceRange BodyRange;
if (Stmt *Body = FD->getBody()) BodyRange = Body->getSourceRange();
+ CurEHLocation = BodyRange.getEnd();
// CalleeWithThisReturn keeps track of the last callee inside this function
// that returns 'this'. Before starting the function, we set it to null.
OpenPOWER on IntegriCloud