aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/IR/LegacyPassManager.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2014-08-24 23:23:06 +0000
committerCraig Topper <craig.topper@gmail.com>2014-08-24 23:23:06 +0000
commit4627679cece264a966faa82a7c5bb79f273d5b6e (patch)
tree227f40fbf1eb4d5208e75d3eb98ba20e829feaa6 /llvm/lib/IR/LegacyPassManager.cpp
parent085fc4d6c679055fc603650e7d29579b262e11a8 (diff)
downloadllvm-4627679cece264a966faa82a7c5bb79f273d5b6e.zip
llvm-4627679cece264a966faa82a7c5bb79f273d5b6e.tar.gz
llvm-4627679cece264a966faa82a7c5bb79f273d5b6e.tar.bz2
Use range based for loops to avoid needing to re-mention SmallPtrSet size.
llvm-svn: 216351
Diffstat (limited to 'llvm/lib/IR/LegacyPassManager.cpp')
-rw-r--r--llvm/lib/IR/LegacyPassManager.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/IR/LegacyPassManager.cpp b/llvm/lib/IR/LegacyPassManager.cpp
index 319915a..5ba0857 100644
--- a/llvm/lib/IR/LegacyPassManager.cpp
+++ b/llvm/lib/IR/LegacyPassManager.cpp
@@ -573,9 +573,8 @@ void PMTopLevelManager::collectLastUses(SmallVectorImpl<Pass *> &LastUses,
return;
SmallPtrSet<Pass *, 8> &LU = DMI->second;
- for (SmallPtrSet<Pass *, 8>::iterator I = LU.begin(),
- E = LU.end(); I != E; ++I) {
- LastUses.push_back(*I);
+ for (Pass *LUP : LU) {
+ LastUses.push_back(LUP);
}
}