This revision was automatically updated to reflect the committed changes.
Closed by commit rG8c2cf499e611: [clang][Tooling] Add a way to tokenize a
FileRange (authored by kadircet).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74962/new/
kadircet updated this revision to Diff 246646.
kadircet added a comment.
- Address comments
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74962/new/
https://reviews.llvm.org/D74962
Files:
clang/include/clang/Tooling/Syntax/Tokens.h
kadircet marked 2 inline comments as done.
kadircet added inline comments.
Comment at: clang/lib/Tooling/Syntax/Tokens.cpp:335
clang::Token T;
- while (!L.LexFromRawLexer(T))
+ while (!L.LexFromRawLexer(T) && L.getCurrentBufferOffset() < FR.endOffset())
AddToken(T);
sammccall added inline comments.
Comment at: clang/lib/Tooling/Syntax/Tokens.cpp:335
clang::Token T;
- while (!L.LexFromRawLexer(T))
+ while (!L.LexFromRawLexer(T) && L.getCurrentBufferOffset() < FR.endOffset())
AddToken(T);
Discussed offline, this
kadircet created this revision.
kadircet added a reviewer: sammccall.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D74962
Files:
clang/include/clang/Tooling/Syntax/Tokens.h