aboutsummaryrefslogtreecommitdiff
path: root/lib/Transforms/Utils/Local.cpp
diff options
context:
space:
mode:
authorJay Foad <jay.foad@gmail.com>2011-04-19 15:23:29 +0000
committerJay Foad <jay.foad@gmail.com>2011-04-19 15:23:29 +0000
commit1a0390253b3e7c2327139d81e5a8c16d5bf85aa8 (patch)
tree7455287753e0f82e2c0f9b874b52162c929d883b /lib/Transforms/Utils/Local.cpp
parentea70a06fa7e684ed55eb4a05c48974e6a8fa2ccc (diff)
Trivial simplification.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129759 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/Local.cpp')
-rw-r--r--lib/Transforms/Utils/Local.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/Transforms/Utils/Local.cpp b/lib/Transforms/Utils/Local.cpp
index cc508a47de..614e4114e9 100644
--- a/lib/Transforms/Utils/Local.cpp
+++ b/lib/Transforms/Utils/Local.cpp
@@ -68,8 +68,7 @@ bool llvm::ConstantFoldTerminator(BasicBlock *BB) {
// Let the basic block know that we are letting go of it. Based on this,
// it will adjust it's PHI nodes.
- assert(BI->getParent() && "Terminator not inserted in block!");
- OldDest->removePredecessor(BI->getParent());
+ OldDest->removePredecessor(BB);
// Replace the conditional branch with an unconditional one.
BranchInst::Create(Destination, BI);