-
Notifications
You must be signed in to change notification settings - Fork 0
/
.clang-format
154 lines (102 loc) · 2.79 KB
/
.clang-format
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
154
BasedOnStyle: LLVM
Language: Cpp
Standard: c++17
# macros
MacroBlockBegin: .*_ENTER
MacroBlockEnd: .*_EXIT
# tabs and indentation
TabWidth: 2
UseTab: Never
IndentWidth: 2
ContinuationIndentWidth: 4
IndentPPDirectives: BeforeHash
IndentExternBlock: NoIndent
NamespaceIndentation: None
IndentWrappedFunctionNames: false
AccessModifierOffset: -1
IndentCaseLabels: true
IndentCaseBlocks: true
# wrapping
ColumnLimit: 0
AlwaysBreakAfterReturnType: None
AlwaysBreakTemplateDeclarations: MultiLine
BreakBeforeBraces: Custom
BreakBeforeBinaryOperators: None
BreakBeforeTernaryOperators: false
BreakConstructorInitializers: BeforeColon
BreakInheritanceList: AfterColon
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
IndentBraces: false
AfterExternBlock: true
AfterNamespace: true
SplitEmptyNamespace: false
AfterClass: true
AfterStruct: true
SplitEmptyRecord: false
AfterEnum: true
AfterUnion: true
AfterFunction: true
SplitEmptyFunction: false
BeforeLambdaBody: false
AfterControlStatement: MultiLine
BeforeElse: true
AfterCaseLabel: false
BeforeCatch: true
ReflowComments: true
BreakStringLiterals: true
AlwaysBreakBeforeMultilineStrings: true
KeepEmptyLinesAtTheStartOfBlocks: false
MaxEmptyLinesToKeep: 2
# transformation
SortIncludes: false
IncludeBlocks: Preserve
SortUsingDeclarations: false
Cpp11BracedListStyle: true
FixNamespaceComments: true
InsertTrailingCommas: None
# spacing
SpaceAfterLogicalNot: false
SpaceBeforeAssignmentOperators: true
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeRangeBasedForLoopColon: true
BitFieldColonSpacing: Both
SpacesInAngles: false
SpaceAfterTemplateKeyword: false
SpacesInParentheses: false
SpaceInEmptyParentheses: false
SpaceBeforeParens: ControlStatements
SpacesInConditionalStatement: false
SpacesInSquareBrackets: false
SpacesInContainerLiterals: false
SpaceInEmptyBlock: true
SpaceBeforeCpp11BracedList: false
SpacesBeforeTrailingComments: 1
SpacesInCStyleCastParentheses: false
SpaceAfterCStyleCast: true
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
# alignment
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignOperands: Align
PointerAlignment: Left
AlignConsecutiveBitFields: true
AlignConsecutiveDeclarations: true
AlignEscapedNewlines: Right
AlignConsecutiveMacros: true
AlignTrailingComments: true
# brevity
AllowAllArgumentsOnNextLine: true
AllowAllConstructorInitializersOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Always
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: Always
AllowShortLambdasOnASingleLine: All
AllowShortLoopsOnASingleLine: true
AllowShortEnumsOnASingleLine: true
CompactNamespaces: true