summaryrefslogtreecommitdiff
path: root/lib/Transforms
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-04-12 18:51:33 +0000
committerChris Lattner <sabre@nondot.org>2005-04-12 18:51:33 +0000
commit151c80be8180a7a0aa1594848699aa6b678b3998 (patch)
tree422dbbfa0355f8e7063690671b2f889bff86388d /lib/Transforms
parente8fd25f5c5eaf8f04c60ca66551aee9b66591a14 (diff)
Get rid of this for_each loop
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21253 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r--lib/Transforms/Utils/SimplifyCFG.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Transforms/Utils/SimplifyCFG.cpp b/lib/Transforms/Utils/SimplifyCFG.cpp
index 4954c7262a3..12af5b04d59 100644
--- a/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/lib/Transforms/Utils/SimplifyCFG.cpp
@@ -837,8 +837,8 @@ bool llvm::SimplifyCFG(BasicBlock *BB) {
// Loop through all of our successors and make sure they know that one
// of their predecessors is going away.
- for_each(succ_begin(BB), succ_end(BB),
- std::bind2nd(std::mem_fun(&BasicBlock::removePredecessor), BB));
+ for (succ_iterator SI = succ_begin(BB), E = succ_end(BB); SI != E; ++SI)
+ SI->removePredecessor(BB);
while (!BB->empty()) {
Instruction &I = BB->back();