diff options
author | Mark de Wever <koraq@xs4all.nl> | 2019-12-22 19:13:34 +0100 |
---|---|---|
committer | Mark de Wever <koraq@xs4all.nl> | 2019-12-22 19:13:34 +0100 |
commit | b6d9e976629ac655e0ed2655289e90357107793f (patch) | |
tree | d59c416986a4c8d4fbb63bcad465bcd61345477b /clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp | |
parent | 536c9a604e82f0c0284595344b8ab9dd601071cf (diff) | |
download | bcm5719-llvm-b6d9e976629ac655e0ed2655289e90357107793f.tar.gz bcm5719-llvm-b6d9e976629ac655e0ed2655289e90357107793f.zip |
[Analyzer] Fixes -Wrange-loop-analysis warnings
This avoids new warnings due to D68912 adds -Wrange-loop-analysis to -Wall.
Differential Revision: https://reviews.llvm.org/D71809
Diffstat (limited to 'clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp b/clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp index f47776c711a..eb962a2ffd9 100644 --- a/clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/IteratorModeling.cpp @@ -1100,7 +1100,7 @@ void IteratorModeling::printState(raw_ostream &Out, ProgramStateRef State, if (!ContMap.isEmpty()) { Out << Sep << "Container Data :" << NL; - for (const auto Cont : ContMap) { + for (const auto &Cont : ContMap) { Cont.first->dumpToStream(Out); Out << " : [ "; const auto CData = Cont.second; @@ -1122,7 +1122,7 @@ void IteratorModeling::printState(raw_ostream &Out, ProgramStateRef State, if (!SymbolMap.isEmpty() || !RegionMap.isEmpty()) { Out << Sep << "Iterator Positions :" << NL; - for (const auto Sym : SymbolMap) { + for (const auto &Sym : SymbolMap) { Sym.first->dumpToStream(Out); Out << " : "; const auto Pos = Sym.second; @@ -1132,7 +1132,7 @@ void IteratorModeling::printState(raw_ostream &Out, ProgramStateRef State, Pos.getOffset()->dumpToStream(Out); } - for (const auto Reg : RegionMap) { + for (const auto &Reg : RegionMap) { Reg.first->dumpToStream(Out); Out << " : "; const auto Pos = Reg.second; |