.clang-format 3.26 KiB
---
# They don't have C, therefore Cpp...
Language:        Cpp
# BasedOnStyle:  LLVM
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlinesLeft: false
AlignOperands:   true
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
# This is deprecated
#AlwaysBreakAfterDefinitionReturnType: TopLevel
AlwaysBreakAfterReturnType: TopLevelDefinitions
AlwaysBreakBeforeMultilineStrings: false
# C++ specific
#AlwaysBreakTemplateDeclarations: false
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
# C++ specific
#  AfterClass:      false
  AfterControlStatement: false
  AfterEnum:       true
  AfterFunction:   true
# C++ specific
#  AfterNamespace:  false
# ObjC specific
#  AfterObjCDeclaration: false
  AfterStruct:     true
  AfterUnion:      true
# C++ specific
#  BeforeCatch:     false
  BeforeElse:      false
  IndentBraces:    false
BreakBeforeBinaryOperators: All
BreakBeforeBraces: Linux
BreakBeforeTernaryOperators: true
# C++ specific
#BreakConstructorInitializersBeforeComma: false
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: true
ColumnLimit:     90
CommentPragmas:  '^ IWYU pragma:'
# C++ specific
#ConstructorInitializerAllOnOneLineOrOnePerLine: false
#ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 2
# C++ specific
#Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat:   false
ExperimentalAutoDetectBinPacking: false
ForEachMacros:   [ HASH_ITER ]
# This is pretty irrelevant, as we don't include files from
# specific directories.
# IncludeCategories:
#   - Regex:           '^"(llvm|llvm-c|clang|clang-c)/'
#     Priority:        2
#   - Regex:           '^(<|"(gtest|isl|json)/)'
#     Priority:        3
#   - Regex:           '.*'
#     Priority:        1
IncludeIsMainRegex: '$' IndentCaseLabels: false IndentWidth: 4 IndentWrappedFunctionNames: false #JavaScriptQuotes: Leave #JavaScriptWrapImports: true KeepEmptyLinesAtTheStartOfBlocks: true # FIXME we will have such macros in the ICM code generation MacroBlockBegin: 'ASSURE_TYPE_HEADER|BLOCK_BEGIN|BLOCK_NOVAR_BEGIN|FOR_LOOP_BEGIN|IF_BEGIN|ELSE_BEGIN' MacroBlockEnd: 'ASSURE_TYPE_FOOTER|BLOCK_END|BLOCK_NOVAR_END|FOR_LOOP_END|IF_END|ELSE_END' MaxEmptyLinesToKeep: 1 # C++ specific #NamespaceIndentation: None # ObjC specific #ObjCBlockIndentWidth: 2 #ObjCSpaceAfterProperty: false #ObjCSpaceBeforeProtocolList: true PenaltyBreakBeforeFirstCallParameter: 3000000 PenaltyBreakComment: 300 PenaltyBreakFirstLessLess: 120 PenaltyBreakString: 1000 PenaltyExcessCharacter: 1000000 PenaltyReturnTypeOnItsOwnLine: 60 PointerAlignment: Right ReflowComments: true SortIncludes: false SpaceAfterCStyleCast: false SpaceAfterTemplateKeyword: true SpaceBeforeAssignmentOperators: true SpaceBeforeParens: Always SpaceInEmptyParentheses: false SpacesBeforeTrailingComments: 1 SpacesInAngles: false SpacesInContainerLiterals: true SpacesInCStyleCastParentheses: false SpacesInParentheses: false SpacesInSquareBrackets: false Standard: Cpp11 TabWidth: 8 UseTab: Never ...