diff options
Diffstat (limited to 'clang/lib/Format/NamespaceEndCommentsFixer.cpp')
| -rw-r--r-- | clang/lib/Format/NamespaceEndCommentsFixer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/Format/NamespaceEndCommentsFixer.cpp b/clang/lib/Format/NamespaceEndCommentsFixer.cpp index 0c34c6126c21..9fb6c5142672 100644 --- a/clang/lib/Format/NamespaceEndCommentsFixer.cpp +++ b/clang/lib/Format/NamespaceEndCommentsFixer.cpp @@ -210,8 +210,8 @@ std::pair<tooling::Replacements, unsigned> NamespaceEndCommentsFixer::analyze( // Spin through the lines and ensure we have balanced braces. int Braces = 0; - for (size_t I = 0, E = AnnotatedLines.size(); I != E; ++I) { - FormatToken *Tok = AnnotatedLines[I]->First; + for (AnnotatedLine *Line : AnnotatedLines) { + FormatToken *Tok = Line->First; while (Tok) { Braces += Tok->is(tok::l_brace) ? 1 : Tok->is(tok::r_brace) ? -1 : 0; Tok = Tok->Next; |
