This revision was automatically updated to reflect the committed changes.
Closed by commit rL317886: [clang-format] Support python-style comments in text
protos (authored by krasimir).
Repository:
rL LLVM
https://reviews.llvm.org/D39806
Files:
cfe/trunk/lib/Format/BreakableToken.cpp
cfe/t
krasimir updated this revision to Diff 122420.
krasimir marked 3 inline comments as done.
krasimir added a comment.
- [clang-format] Address review comments
https://reviews.llvm.org/D39806
Files:
lib/Format/BreakableToken.cpp
lib/Format/FormatTokenLexer.cpp
lib/Format/FormatTokenLexer.h
djasper accepted this revision.
djasper added inline comments.
This revision is now accepted and ready to land.
Comment at: lib/Format/FormatTokenLexer.cpp:344
+ size_t To = Lex->getBuffer().find_first_of('\n', From);
+ if (To == StringRef::npos) To = Lex->getBuffer().size();
+
bkramer added inline comments.
Comment at: lib/Format/BreakableToken.cpp:48
+ static const SmallVector KnownTextProtoPrefixes{"//", "#"};
+ const SmallVectorImpl &KnownPrefixes =
+ (Style.Language == FormatStyle::LK_TextProto) ? KnownTextProtoPrefixes
Thes