From 24fd7eed8adef2907c45d84eb71ddc313f8854e2 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Wed, 3 Jul 2013 04:42:33 +0000 Subject: [PATCH] Use SmallVectorImpl::iterator/const_iterator instead of SmallVector to avoid specifying the vector size. llvm-svn: 185509 --- llvm/lib/CodeGen/LexicalScopes.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/llvm/lib/CodeGen/LexicalScopes.cpp b/llvm/lib/CodeGen/LexicalScopes.cpp index 6ea0aa4eb519..f7ba12539ec5 100644 --- a/llvm/lib/CodeGen/LexicalScopes.cpp +++ b/llvm/lib/CodeGen/LexicalScopes.cpp @@ -220,7 +220,7 @@ void LexicalScopes::constructScopeNest(LexicalScope *Scope) { LexicalScope *WS = WorkStack.back(); const SmallVectorImpl &Children = WS->getChildren(); bool visitedChildren = false; - for (SmallVector::const_iterator SI = Children.begin(), + for (SmallVectorImpl::const_iterator SI = Children.begin(), SE = Children.end(); SI != SE; ++SI) { LexicalScope *ChildScope = *SI; if (!ChildScope->getDFSOut()) { @@ -280,7 +280,7 @@ getMachineBasicBlocks(DebugLoc DL, } SmallVectorImpl &InsnRanges = Scope->getRanges(); - for (SmallVector::iterator I = InsnRanges.begin(), + for (SmallVectorImpl::iterator I = InsnRanges.begin(), E = InsnRanges.end(); I != E; ++I) { InsnRange &R = *I; MBBs.insert(R.first->getParent());