-
Notifications
You must be signed in to change notification settings - Fork 0
/
.clang-format
76 lines (66 loc) · 1.99 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
# http://clang.llvm.org/docs/ClangFormatStyleOptions.html
BasedOnStyle: LLVM
AlignAfterOpenBracket: DontAlign
AccessModifierOffset: -4
AlignConsecutiveAssignments: true
#AlignConsecutiveDeclarations: true
AlignEscapedNewlinesLeft: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: true
AllowShortLoopsOnASingleLine: false
AlwaysBreakTemplateDeclarations: true
BinPackArguments: true
BinPackParameters: false
BreakBeforeBraces: Custom
BraceWrapping:
AfterClass: true
AfterControlStatement: true
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterObjCDeclaration: true
AfterStruct: true
AfterUnion: true
# AfterExternBlock: true # clang-format 6
BeforeCatch: true
BeforeElse: true
IndentBraces: false
SplitEmptyFunction: false # clang-format 5
SplitEmptyRecord: false # clang-format 5
SplitEmptyNamespace: false # clang-format 5
BreakBeforeBinaryOperators: NonAssignment
BreakBeforeInheritanceComma: true # clang-format 5
BreakConstructorInitializers: BeforeComma # clang-format 5
ColumnLimit: 140
IndentWidth: 4
# KeepEmptyLinesAtTheStartOfBlocks: true
IncludeCategories:
- Regex: '^(<|")api/'
Priority: 3
- Regex: '^(<|")apps/'
Priority: 3
- Regex: '^(<|")qdb/'
Priority: 3
- Regex: '^(<|")tests/'
Priority: 3
- Regex: '^(<|")(mach|linux|sys)/'
Priority: 7
- Regex: '^(<|")windows'
Priority: 7
- Regex: '^<experimental/'
Priority: 8
- Regex: '^(<|")[-a-zA-Z0-9_]+/'
Priority: 5
- Regex: '^<'
Priority: 9
- Regex: '^"[^/]*'
Priority: 1
NamespaceIndentation: None
# PPDirectiveIndentation: All
PointerAlignment: Middle
# SpaceBeforeOperators: true
SpacesInAngles: false
TabWidth: 4
UseTab: Never