From 80af98645baf095765c87cd2287cf49fec86fa4a Mon Sep 17 00:00:00 2001 From: Peter Rozsa Date: Wed, 27 Sep 2023 08:51:29 +0200 Subject: [PATCH] IMPALA-12469: Allow short if statements on a single line in clang-format This change allows short if statements and blocks to be put on a single line, clang-format will keep these constructions as-is. Change-Id: I65d04f00187648fafab89c82cb01ffd9ea17c4bb Reviewed-on: http://gerrit.cloudera.org:8080/20513 Reviewed-by: Daniel Becker Reviewed-by: Tamas Mate Tested-by: Tamas Mate --- .clang-format | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.clang-format b/.clang-format index 054cb3056..aad646bda 100644 --- a/.clang-format +++ b/.clang-format @@ -27,6 +27,8 @@ Language: Java BasedOnStyle: Chromium AllowShortCaseLabelsOnASingleLine: true AllowShortFunctionsOnASingleLine: All +AllowShortIfStatementsOnASingleLine: true +AllowShortBlocksOnASingleLine: true AlwaysBreakBeforeMultilineStrings: true BreakBeforeTernaryOperators: false ColumnLimit: 90