summaryrefslogtreecommitdiffstats
path: root/llvm/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
commit95f16a3ac439ccc079f32dc830d0754f11492189 (patch)
tree0ca142c664918c82bfaaa8ba36522d564acb40f6 /llvm/lib/Transforms
parentfd469bddace11602420b1ace89897e929de4b0e8 (diff)
downloadbcm5719-llvm-95f16a3ac439ccc079f32dc830d0754f11492189.tar.gz
bcm5719-llvm-95f16a3ac439ccc079f32dc830d0754f11492189.zip
Get rid of this for_each loop
llvm-svn: 21253
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/Utils/SimplifyCFG.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
index 4954c7262a3..12af5b04d59 100644
--- a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/llvm/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();
OpenPOWER on IntegriCloud