-
Notifications
You must be signed in to change notification settings - Fork 2
/
clang-format.intent.yaml
77 lines (67 loc) · 2.06 KB
/
clang-format.intent.yaml
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
Language: Cpp
BasedOnStyle: Chromium
# Indentation
# There might be other settings we'd like to specify here, we'll see
TabWidth: 4
UseTab: Always
AccessModifierOffset: -4
IndentCaseLabels: true
IndentWidth: 4
# Interesting options we should keep an eye out in the next release:
# this is currently overridden by BS_Allman in version 11, but hope they'll
# change it
# IndentExternBlock: NoIndent
# We really want BS_Allman, but we want to unindent extern "C"
# Once LLVM 11 is released, see if IndentExternBlock: NoIndent works
# BreakBeforeBraces: Allman
BreakBeforeBraces: Custom
BraceWrapping:
AfterCaseLabel: true
AfterClass: true
AfterControlStatement: true
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterObjCDeclaration: true
AfterStruct: true
AfterUnion: true
AfterExternBlock: false
BeforeCatch: true
BeforeElse: true
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: true
BinPackParameters: true
BreakBeforeBinaryOperators: None
ConstructorInitializerAllOnOneLineOrOnePerLine: true
DerivePointerAlignment: false
MaxEmptyLinesToKeep: 3
PointerAlignment: Right
SpaceAfterCStyleCast: true
SpacesBeforeTrailingComments: 2
SortIncludes: true
IncludeBlocks: Regroup
IncludeCategories:
- Regex: '^<ext/.*\.h>'
Priority: 2
- Regex: '^<.*\.h>'
Priority: 1
- Regex: '^<.*'
Priority: 2
- Regex: '"postgres\.h"'
Priority: -1
- Regex: '"gpos/.*'
Priority: 3
- Regex: '"(gpopt|naucrates|gpdbcost)/.*'
Priority: 4
# TODO: reflow comments
# when we get to it, should probably bite the bullet and add a bunch of no-lint
# comment around problematic areas
ReflowComments: false
# TODO: break literal strings, once we resolve Wstring-concatenation
BreakStringLiterals: false