diff options
author | John McCall <rjmccall@apple.com> | 2011-01-26 19:15:39 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2011-01-26 19:15:39 +0000 |
commit | 4bbcbda302cba8b1b0d88c20d735d09b483bd005 (patch) | |
tree | c34aff62be9783d6c1ab505f5aa1972132207593 /lib/CodeGen/CGException.cpp | |
parent | 192e7f7e7f0493f7cdfda1d752e6de340d4e3ffe (diff) |
Fix some obvious bugs in the conditional-cleanup code and then make the
dtor cleanup use it.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124309 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGException.cpp')
-rw-r--r-- | lib/CodeGen/CGException.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/CodeGen/CGException.cpp b/lib/CodeGen/CGException.cpp index 5845f1ec02..58af36a56d 100644 --- a/lib/CodeGen/CGException.cpp +++ b/lib/CodeGen/CGException.cpp @@ -179,8 +179,7 @@ llvm::Value *CodeGenFunction::initFullExprCleanup() { // Initialize it to false at a site that's guaranteed to be run // before each evaluation. llvm::BasicBlock *block = OutermostConditional->getStartingBlock(); - new llvm::StoreInst(Builder.getFalse(), run, - block->getFirstNonPHIOrDbg()); + new llvm::StoreInst(Builder.getFalse(), run, &block->back()); // Initialize it to true at the current location. Builder.CreateStore(Builder.getTrue(), run); |