]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
clang-format: set SpaceBeforeParens to ControlStatementsExceptForEachMacros
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Mon, 16 Nov 2020 00:11:50 +0000 (00:11 +0000)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 16 Nov 2020 07:57:51 +0000 (16:57 +0900)
I contributed this option to LLVM a while ago to reduce the amount of
changes clang-format makes when formatting systemd source files. As
LLVM 11 is now starting to becomes widely available, let's configure
it in the clang-format config.

.clang-format

index 8e5cfca535ed67c400cfc3673e1a7a36c0f4c9ae..651249c701b4e63949034ed6aeabcb22faca3726 100644 (file)
@@ -118,6 +118,7 @@ PenaltyBreakString: 0
 PenaltyExcessCharacter: 10
 PenaltyReturnTypeOnItsOwnLine: 100
 SpaceAfterCStyleCast: true
+SpaceBeforeParens: ControlStatementsExceptForEachMacros
 SpacesInAngles:  true
 TabWidth:        8
 UseCRLF:         false