diff options
author | Craig Topper <craig.topper@gmail.com> | 2013-07-04 03:08:24 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2013-07-04 03:08:24 +0000 |
commit | 2341c0d3b2aedbb090c3769dc44b3c403d46f9e9 (patch) | |
tree | 8fdfccfc9bc4eadda9498ef660b36f06dc75040f /clang/lib/Sema/SemaLambda.cpp | |
parent | a42fb525e43ba27f82d361236d47811b3d1073de (diff) | |
download | bcm5719-llvm-2341c0d3b2aedbb090c3769dc44b3c403d46f9e9.tar.gz bcm5719-llvm-2341c0d3b2aedbb090c3769dc44b3c403d46f9e9.zip |
Use SmallVectorImpl instead of SmallVector for iterators and references to avoid specifying the vector size unnecessarily.
llvm-svn: 185610
Diffstat (limited to 'clang/lib/Sema/SemaLambda.cpp')
-rw-r--r-- | clang/lib/Sema/SemaLambda.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/lib/Sema/SemaLambda.cpp b/clang/lib/Sema/SemaLambda.cpp index b2dbf0553f4..1e6ef9baf70 100644 --- a/clang/lib/Sema/SemaLambda.cpp +++ b/clang/lib/Sema/SemaLambda.cpp @@ -608,10 +608,10 @@ void Sema::ActOnStartOfLambdaDefinition(LambdaIntroducer &Intro, // Handle explicit captures. SourceLocation PrevCaptureLoc = Intro.Default == LCD_None? Intro.Range.getBegin() : Intro.DefaultLoc; - for (SmallVector<LambdaCapture, 4>::const_iterator - C = Intro.Captures.begin(), - E = Intro.Captures.end(); - C != E; + for (SmallVectorImpl<LambdaCapture>::const_iterator + C = Intro.Captures.begin(), + E = Intro.Captures.end(); + C != E; PrevCaptureLoc = C->Loc, ++C) { if (C->Kind == LCK_This) { // C++11 [expr.prim.lambda]p8: |