This revision was automatically updated to reflect the committed changes.
Closed by commit rG14c30c70c459: [clang-format] Avoid crash in
LevelIndentTracker. (authored by curdeius).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129064/new/
https://re
curdeius updated this revision to Diff 442482.
curdeius marked an inline comment as done.
curdeius added a comment.
Address comments.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129064/new/
https://reviews.llvm.org/D129064
Files:
clang/lib/For
owenpan added inline comments.
Comment at: clang/lib/Format/UnwrappedLineFormatter.cpp:62-70
while (IndentForLevel.size() <= Line.Level)
IndentForLevel.push_back(-1);
if (Line.InPPDirective) {
unsigned IndentWidth =
(Style.PPIndentWidth >= 0) ?
HazardyKnusperkeks added inline comments.
Comment at: clang/lib/Format/UnwrappedLineFormatter.cpp:62-70
while (IndentForLevel.size() <= Line.Level)
IndentForLevel.push_back(-1);
if (Line.InPPDirective) {
unsigned IndentWidth =
(Style.PPIndentWid
owenpan added inline comments.
Comment at: clang/lib/Format/UnwrappedLineFormatter.cpp:69-70
} else {
- IndentForLevel.resize(Line.Level + 1);
+ if (IndentForLevel.size() < Line.Level + 1)
+IndentForLevel.resize(Line.Level + 1);
Indent = getIndent(Li
MyDeveloperDay accepted this revision.
MyDeveloperDay added a comment.
LGTM
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129064/new/
https://reviews.llvm.org/D129064
___
cfe-commits mailing list
cfe-com
curdeius created this revision.
curdeius added reviewers: HazardyKnusperkeks, owenpan, MyDeveloperDay.
Herald added a project: All.
curdeius requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
Fixes https://github.com/llvm/llvm-project/issues/5