summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2015-09-10 16:25:38 +0000
committerSanjay Patel <spatel@rotateright.com>2015-09-10 16:25:38 +0000
commitf4b34b76d4521dd01a0760b0ccd4fedf67a0b6d5 (patch)
treeb7f424776d9d7563dbda767525a399fce8b64733
parent5e7bd91891a36d5639938a766e2ea5a128029085 (diff)
downloadbcm5719-llvm-f4b34b76d4521dd01a0760b0ccd4fedf67a0b6d5.tar.gz
bcm5719-llvm-f4b34b76d4521dd01a0760b0ccd4fedf67a0b6d5.zip
use range-based for loop; NFCI
llvm-svn: 247294
-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 c2c8cb2a3b4..da20f7e30f7 100644
--- a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
@@ -971,8 +971,8 @@ bool SimplifyCFGOpt::FoldValueComparisonIntoPredecessors(TerminatorInst *TI,
// Okay, at this point, we know which new successor Pred will get. Make
// sure we update the number of entries in the PHI nodes for these
// successors.
- for (unsigned i = 0, e = NewSuccessors.size(); i != e; ++i)
- AddPredecessorToBlock(NewSuccessors[i], Pred, BB);
+ for (BasicBlock *NewSuccessor : NewSuccessors)
+ AddPredecessorToBlock(NewSuccessor, Pred, BB);
Builder.SetInsertPoint(PTI);
// Convert pointer to int before we switch.
OpenPOWER on IntegriCloud