timwoj added inline comments.
================ Comment at: clang/lib/Format/UnwrappedLineParser.cpp:2967 + // needs to be indented. + bool ClosesBlock = + Line->MatchingOpeningBlockLineIndex != UnwrappedLine::kInvalidIndex && ---------------- curdeius wrote: > Please move below to the place of use. Also, just naming it `ClosesBlock` is > a bit misleading as it is only for Whitesmiths style. I agree with renaming it, but I'm not sure on moving it to where it's used. It relies on `Line->MatchingOpeningBlockLineIndex` which is reset shortly after this boolean value is calculated. ================ Comment at: clang/unittests/Format/FormatTest.cpp:13688 - WhitesmithsBraceStyle.IndentCaseBlocks = true; + WhitesmithsBraceStyle.IndentCaseLabels = true; verifyFormat("void switchTest1(int a)\n" ---------------- curdeius wrote: > Hmm, you don't test the same thing anymore... This change was intentional. According to the clang-format documentation, `IndentCaseBlocks` effectively just changes the brace breaking for the block after a case label. Given that it always breaks for Whitesmiths, `IndentCaseBlocks` can be effectively ignored for that style. I changed it to test the `IndentCaseLabels` instead because that tests indentation for the whole block. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94500/new/ https://reviews.llvm.org/D94500 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits