LiteLoaderBDS-1.16.40/.clang-format
2023-03-03 10:18:21 -08:00

75 lines
2.2 KiB
YAML

# Documents: https://clang.llvm.org/docs/ClangFormatStyleOptions.html
Language: Cpp
BasedOnStyle: LLVM
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: None
AlignConsecutiveDeclarations: None
AlignOperands: Align
AlwaysBreakTemplateDeclarations: Yes
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: Always
AllowShortCaseLabelsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AllowShortFunctionsOnASingleLine: Empty
AllowShortLambdasOnASingleLine: All
AllowShortEnumsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
BinPackArguments: true
BinPackParameters: true
ConstructorInitializerIndentWidth: 0
ConstructorInitializerAllOnOneLineOrOnePerLine: true
BreakBeforeConceptDeclarations: Always
RequiresClausePosition: OwnLine
ColumnLimit: 120
CommentPragmas: '^ IWYU pragma:'
PointerAlignment: Left
IndentWidth: 4
SortIncludes: Never
MaxEmptyLinesToKeep: 2
SpacesInSquareBrackets: false
SpacesInParentheses: false
SpaceBeforeAssignmentOperators: true
SpacesInContainerLiterals: true
IndentWrappedFunctionNames: true
KeepEmptyLinesAtTheStartOfBlocks: true
SeparateDefinitionBlocks: Always
BreakConstructorInitializersBeforeComma: true
SpaceAfterCStyleCast: false
IndentCaseLabels: true
TabWidth: 4
UseTab: Never
BreakBeforeBraces: Custom
BraceWrapping:
# case 语句后面
AfterCaseLabel: false
# class定义后面
AfterClass: false
# enum定义后面
AfterEnum: false
# 函数定义后面
AfterFunction: false
# 命名空间定义后面
AfterNamespace: false
# struct定义后面
AfterStruct: false
# union定义后面
AfterUnion: false
# extern导出块后面
AfterExternBlock: false
# catch之前
BeforeCatch: false
# else之前
BeforeElse: false
# 缩进大括号(整个大括号框起来的部分都缩进)
IndentBraces: false
# 空函数的大括号是否可以在一行
SplitEmptyFunction: true
# 空记录体(struct/class/union)的大括号是否可以在一行
SplitEmptyRecord: true
# 空namespace的大括号是否可以在一行
SplitEmptyNamespace: true