[PATCH] D151954: [clang-format] Fix overlapping whitespace replacements before PPDirective

Owen Pan via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 14 15:30:14 PDT 2023


owenpan updated this revision to Diff 531538.
owenpan edited the summary of this revision.
owenpan added a reviewer: paulkirth.
owenpan removed a subscriber: paulkirth.
owenpan added a comment.

Add a member `Newlines` to `struct FormatToken` and compute it only once in `UnwrappedLineFormatter::formatFirstToken()`.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D151954/new/

https://reviews.llvm.org/D151954

Files:
  clang/lib/Format/FormatToken.h
  clang/lib/Format/UnwrappedLineFormatter.cpp
  clang/unittests/Format/FormatTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151954.531538.patch
Type: text/x-patch
Size: 5852 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230614/5839e290/attachment.bin>


More information about the cfe-commits mailing list