HazardyKnusperkeks created this revision.
HazardyKnusperkeks added reviewers: MyDeveloperDay, curdeius.
HazardyKnusperkeks added a project: clang-format.
HazardyKnusperkeks requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
When sorting the kn
curdeius added inline comments.
Comment at: clang/lib/Format/BreakableToken.cpp:44
const FormatStyle &Style) {
+ // Keep these prefixes sorted after length.
static constexpr StringRef KnownCStylePrefixes[] = {"///<", "//!<", "///",
HazardyKnusperkeks updated this revision to Diff 318151.
HazardyKnusperkeks added a comment.
Now with `assert`.
We could do a `static_assert`, but then we would have to write our own
`is_sorted`, since the `std` is only `constexpr` in C++20.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE
HazardyKnusperkeks updated this revision to Diff 318156.
HazardyKnusperkeks added a comment.
Empty lines removed.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95081/new/
https://reviews.llvm.org/D95081
Files:
clang/lib/Format/BreakableToken.cpp
curdeius accepted this revision.
curdeius added a comment.
This revision is now accepted and ready to land.
Just an assert is ok IMO. We may fix it when LLVM will be compiled with C++20
but this code may change before it happens.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
This revision was automatically updated to reflect the committed changes.
Closed by commit rG7c8b9c102f38: [clang-format] [NFC] Restructure
getLineCommentIndentPrefix (authored by HazardyKnusperkeks).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D950