-
Notifications
You must be signed in to change notification settings - Fork 71
Expand file tree
/
Copy path.clang-format
More file actions
153 lines (131 loc) · 3.44 KB
/
.clang-format
File metadata and controls
153 lines (131 loc) · 3.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
# clang-format configuration
UseTab: Never
ColumnLimit: 100
# Indent
IndentWidth: 4
BracedInitializerIndentWidth: 4
AccessModifierOffset: -4
IndentAccessModifiers: false
IndentCaseLabels: true
IndentExternBlock: Indent
IndentGotoLabels: true
IndentRequiresClause: true
IndentWrappedFunctionNames: true
NamespaceIndentation: None
LambdaBodyIndentation: Signature
BitFieldColonSpacing: Both
# Insert
InsertBraces: false
InsertNewlineAtEOF: true
KeepEmptyLinesAtEOF: true
# Align
AlignAfterOpenBracket: true
AlignTrailingComments:
Kind: Always
AlignArrayOfStructures: Left
PointerAlignment: Left
BreakAfterAttributes: Leave
BreakAfterReturnType: Automatic
PenaltyReturnTypeOnItsOwnLine: 100
BreakBeforeConceptDeclarations: Always
BreakBeforeInlineASMColon: OnlyMultiline
BreakBeforeTernaryOperators: true
BreakConstructorInitializers: AfterColon
BreakInheritanceList: AfterColon
BreakAdjacentStringLiterals: false
BreakStringLiterals: false
CompactNamespaces: false
Cpp11BracedListStyle: true
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: Always
AllowAllArgumentsOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowBreakBeforeNoexceptSpecifier: Never
AllowShortBlocksOnASingleLine: Empty
AllowShortCaseLabelsOnASingleLine: true
AllowShortCompoundRequirementOnASingleLine: true
AllowShortEnumsOnASingleLine: true
AllowShortFunctionsOnASingleLine: Empty
AllowShortIfStatementsOnASingleLine: Never
AllowShortLambdasOnASingleLine: Inline
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: Yes
RequiresClausePosition: OwnLine
BinPackArguments: false
BinPackParameters: OnePerLine
# Space
SeparateDefinitionBlocks: Always
SpaceBeforeParens: Custom
SpaceBeforeParensOptions:
AfterControlStatements: false
AfterForeachMacros: false
AfterFunctionDeclarationName: false
AfterFunctionDefinitionName: false
AfterIfMacros: false
AfterOverloadedOperator: false
AfterRequiresInClause: true
AfterRequiresInExpression: false
BeforeNonEmptyParentheses: false
SpaceBeforeRangeBasedForLoopColon: false
SpaceBeforeSquareBrackets: false
SpaceInEmptyBlock: false
SpacesBeforeTrailingComments: 2
SpacesInAngles: Never
SpacesInParens: Custom
SpacesInParensOptions:
InConditionalStatements: false
InCStyleCasts: false
InEmptyParentheses: false
Other: false
SpacesInSquareBrackets: false
WrapNamespaceBodyWithEmptyLines: Always
# Order
QualifierAlignment: Custom
QualifierOrder: ["constexpr", "const", "inline", "static", "type"]
SortIncludes: true
SortUsingDeclarations: Never
IncludeBlocks: Regroup
IncludeCategories:
- Regex: '^["<](spdlog|toml\+\+|coraing|cpptrace|flatbuffers)/'
Priority: 30
SortPriority: 31
- Regex: '^["<](llvm)/'
Priority: 30
SortPriority: 32
- Regex: '^["<](clang)/'
Priority: 30
SortPriority: 33
- Regex: '^["<](clang-tidy)/'
Priority: 30
SortPriority: 34
- Regex: '^["<](Test)/'
Priority: 20
SortPriority: 22
- Regex: "^<.*"
Priority: 10
SortPriority: 10
- Regex: '^".*/.*"'
Priority: 20
SortPriority: 23
- Regex: ".*"
Priority: 20
SortPriority: 21
ForEachMacros: ["REFLECTABLE_RECORD"]
NamespaceMacros: [TEST_SUITE]
KeepEmptyLines:
AtEndOfFile: false
AtStartOfBlock: false
AtStartOfFile: false
StatementMacros:
- DECO_CFG_START
- DECO_CFG
- DECO_CFG_END
- DecoKV
- DecoFlag
- DecoComma
- DecoInput
- DecoPack
- DecoKVStyled
- DecoMulti