Files
mop3/kernel/.clang-format
2025-12-21 23:10:21 +01:00

59 lines
1.1 KiB
YAML

BasedOnStyle: LLVM
Language: C
# Indentation
IndentWidth: 2
TabWidth: 2
UseTab: Never
# Braces and blocks
BreakBeforeBraces: Attach
BraceWrapping:
AfterFunction: false
AfterControlStatement: false
AfterStruct: false
AfterEnum: false
AfterUnion: false
BeforeElse: false
# Control statements
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AllowShortBlocksOnASingleLine: Never
# Line breaking
ColumnLimit: 80
BreakBeforeBinaryOperators: None
BreakBeforeTernaryOperators: true
BreakStringLiterals: false
# Spacing
SpaceBeforeParens: Always
SpaceBeforeAssignmentOperators: true
SpacesInParentheses: false
SpacesInSquareBrackets: false
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
# Pointer alignment
PointerAlignment: Left
DerivePointerAlignment: false
# Alignment
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignConsecutiveMacros: true
AlignOperands: false
# Includes
SortIncludes: true
# Comments
ReflowComments: false
CommentPragmas: '^ IWYU pragma:'
# Misc
KeepEmptyLinesAtTheStartOfBlocks: false
MaxEmptyLinesToKeep: 1