diff options
Diffstat (limited to 'lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp')
-rw-r--r-- | lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp b/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp index 296aec66805a4..fb07484bfcd9c 100644 --- a/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp +++ b/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp @@ -65,10 +65,9 @@ public: } void VisitChildren(const Stmt *S) { - for (Stmt::const_child_iterator I = S->child_begin(), E = S->child_end(); - I!=E; ++I) - if (const Stmt *child = *I) - VisitChild(S, child); + for (const Stmt *Child : S->children()) + if (Child) + VisitChild(S, Child); } TypeCallPair VisitCastExpr(const CastExpr *E) { |