sstwcw added a comment. Here is one problem:
clang-format -style='{IndentPPDirectives: BeforeHash, PPIndentWidth: 1, IndentWidth: 4, IndentCaseLabels: true}' actual: #define X \ switch (x) { \ case 0: \ break; \ default: \ break; \ } expected: #define X \ switch (x) { \ case 0: \ break; \ default: \ break; \ } Me guessing what caused the problem. You intend for `PPLevel` to mean the depth of `#if` sections. But you accidentally made it change along with `Level` where you shouldn't, for example in `UnwrappedLineParser.cpp: 600`. In addition, I suggest including `PPBranchLevel` in `PPLevel` only instead of also in `Level`. ================ Comment at: clang/lib/Format/UnwrappedLineParser.h:47 + /// The preprocessor indent level of the \c UnwrappedLine. + int PPLevel; ---------------- Please elaborate what preprocessor indent level means. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137181/new/ https://reviews.llvm.org/D137181 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits