From 21b2a54848278ccd69fa8f9c52e374e6a5643d31 Mon Sep 17 00:00:00 2001 From: Felipe Olmos Date: Thu, 13 Jul 2023 12:03:23 +0200 Subject: [PATCH] Fix comment reflow not being idempotent Comment reflow is desirable but it is not idempotent in clang-format 16 when there are tabs in the comments. To fix we temporarily set PenaltyCommentBreak to 500. When clang-format is fixed we may eliminate this setting. --- .clang-format | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.clang-format b/.clang-format index a88aaa117..9676b02c3 100644 --- a/.clang-format +++ b/.clang-format @@ -12,8 +12,12 @@ AlignOperands: true SortIncludes: false UseTab: ForContinuationAndIndentation AllowShortFunctionsOnASingleLine: Empty +ReflowComments: true +PenaltyBreakComment: 500 --- BasedOnStyle: Mozilla Language: Java ColumnLimit: 120 IndentWidth: 8 +ReflowComments: true +PenaltyBreakComment: 500