-
Notifications
You must be signed in to change notification settings - Fork 3
/
.clang-format
67 lines (50 loc) · 1.4 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
# https://clang.llvm.org/docs/ClangFormatStyleOptions.html
Language: Cpp
# BasedOnStyle: Microsoft
Standard : c++14
IndentWidth : 4
AccessModifierOffset : -4
IndentAccessModifiers : false
PointerAlignment: Left
ReferenceAlignment : Left
ColumnLimit : 0
TabWidth: 4
UseTab: Never
# 命名空间缩进
NamespaceIndentation : All
CompactNamespaces : false
# 命名空间结束添加 注释 // namespace XXX
FixNamespaceComments : true
IndentWrappedFunctionNames: false
AlignArrayOfStructures: Left
# public结束后有一个回车
EmptyLineBeforeAccessModifier : LogicalBlock
BreakConstructorInitializers : BeforeComma
BreakInheritanceList : BeforeComma
# template后面不要有空格
SpaceAfterTemplateKeyword : false
Cpp11BracedListStyle : true
# AlignEscapedNewlines : DontAlign
SpaceBeforeCpp11BracedList : true
# AllowAllParametersOfDeclarationOnNextLine : false
SortUsingDeclarations : false
SortIncludes : Never
BreakBeforeBraces: Custom
BraceWrapping:
AfterFunction : true
AfterNamespace : true
AfterUnion : true
AfterExternBlock : true
BeforeElse : true
BeforeWhile : false
SplitEmptyFunction : true
SplitEmptyRecord : true
AfterCaseLabel : true
AfterControlStatement: Always
BeforeLambdaBody : true
AfterClass : true
AfterStruct : true
AfterEnum : true
SpaceBeforeParens : ControlStatements
SpaceBeforeCaseColon : false
SpacesInContainerLiterals : true