[clang] [clang-format] Add KeepEmptyLines.AtEndOfBlock option (PR #224223)
Björn Schäpers via cfe-commits
cfe-commits at lists.llvm.org
Wed Sep 30 03:09:16 PDT 2026
================
@@ -170,6 +170,7 @@ TEST_F(FormatTest, RemovesEmptyLines) {
CustomStyle.BreakBeforeBraces = FormatStyle::BS_Custom;
CustomStyle.BraceWrapping.AfterNamespace = true;
CustomStyle.KeepEmptyLines.AtStartOfBlock = false;
+ CustomStyle.KeepEmptyLines.AtEndOfBlock = false;
----------------
HazardyKnusperkeks wrote:
> So, setting this value to `false` makes sure that if the default will be changed for some reasons this test will not break.
That will **never** happen, as it would break a lot of formatting. Once a default is set, it will not be changed. (This applies to the LLVM style, other styles may adapt, if their owner decides to change their style guide, but that is also controversial.)
https://github.com/llvm/llvm-project/pull/224223
More information about the cfe-commits
mailing list