-
Notifications
You must be signed in to change notification settings - Fork 0
/
.clang-format
134 lines (118 loc) · 2.96 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
BasedOnStyle: Microsoft
ColumnLimit: 120
Language: Cpp
Standard: c++20
IndentWidth: 4
ContinuationIndentWidth: 4
IndentAccessModifiers: False
AccessModifierOffset: -4
IndentCaseLabels: False
IndentExternBlock: NoIndent
IndentGotoLabels: False
IndentPPDirectives: BeforeHash
IndentWrappedFunctionNames: False
LambdaBodyIndentation: Signature
NamespaceIndentation: None
PenaltyReturnTypeOnItsOwnLine: 100000
# Improve chained method calls
PenaltyIndentedWhitespace: 30
InsertTrailingCommas: Wrapped
AlwaysBreakTemplateDeclarations: Yes
SeparateDefinitionBlocks: Always
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: Always
KeepEmptyLinesAtTheStartOfBlocks: False
MaxEmptyLinesToKeep: 1
IncludeBlocks: Regroup
IncludeCategories:
# gtest includes
- Regex: '<gtest/.+>'
Priority: 0
SortPriority: 1
- Regex: '<gmock/.+>'
Priority: 0
SortPriority: 2
# Graphics API includes
- Regex: "<vulkan/.+>"
Priority: 1
SortPriority: 1
CaseSensitive: True
- Regex: "<GLFW/glfw3.h>"
Priority: 1
SortPriority: 2
CaseSensitive: True
# mpfr includes
- Regex: '<mpfr\.h>'
Priority: 8
# pugixml includes
- Regex: '<pugixml\.hpp>'
Priority: 9
# spirv_cross includes
- Regex: '<spirv_cross/.+>'
Priority: 10
# stb_image includes
- Regex: '<stb_image\.h>'
Priority: 11
# tiny_gltf includes
- Regex: '<tiny_gltf\.h>'
Priority: 12
# stl includes
- Regex: "<[[:alnum:]_.]+>"
Priority: 3
# boost includes
- Regex: "<boost/.+>"
Priority: 4
# fmt includes
- Regex: "<fmt/.+>"
Priority: 5
# glm includes
- Regex: "<glm/.+>"
Priority: 6
# gsl includes
- Regex: "<gsl/.+>"
Priority: 7
# Our includes
- Regex: '<[[:alnum:]_/]+\.(hpp|pb.h)>'
Priority: 100
CaseSensitive: True
# Others
- Regex: ".*"
Priority: 1000
# Arguments and parameters
AlignAfterOpenBracket: AlwaysBreak
BinPackArguments: False
BinPackParameters: False
AllowAllArgumentsOnNextLine: False
AllowAllParametersOfDeclarationOnNextLine: False
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: false
AllowShortEnumsOnASingleLine: false
AllowShortFunctionsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: Never
AllowShortLambdasOnASingleLine: Empty
AllowShortLoopsOnASingleLine: false
BreakBeforeBraces: Allman
BreakBeforeTernaryOperators: True
BreakInheritanceList: BeforeComma
PackConstructorInitializers: Never
BreakConstructorInitializers: BeforeComma
SpaceAfterTemplateKeyword: True
SpaceBeforeAssignmentOperators: True
SpaceBeforeCaseColon: False
SpaceBeforeCpp11BracedList: True
Cpp11BracedListStyle: False
SpaceBeforeParens: ControlStatements
SpaceBeforeRangeBasedForLoopColon: True
SpaceBeforeSquareBrackets: False
SpaceInEmptyBlock: False
SpaceInEmptyParentheses: False
FixNamespaceComments: True
ShortNamespaceLines: 0
PointerAlignment: Middle
SpaceAroundPointerQualifiers: Both
ReflowComments: True
---
Language: Proto
BasedOnStyle: google
IndentWidth: 4
ColumnLimit: 80