Skip to content

Commit b6952c5

Browse files
catfactboqs
authored andcommitted
add clang-format
1 parent 1e64c90 commit b6952c5

File tree

1 file changed

+67
-0
lines changed

1 file changed

+67
-0
lines changed

.clang-format

+67
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
---
2+
Language: Cpp
3+
# BasedOnStyle: Google
4+
AccessModifierOffset: -1
5+
AlignAfterOpenBracket: true
6+
AlignConsecutiveAssignments: false
7+
AlignEscapedNewlinesLeft: true
8+
AlignOperands: true
9+
AlignTrailingComments: true
10+
AllowAllParametersOfDeclarationOnNextLine: false
11+
AllowShortBlocksOnASingleLine: true
12+
AllowShortCaseLabelsOnASingleLine: true
13+
AllowShortFunctionsOnASingleLine: All
14+
AllowShortIfStatementsOnASingleLine: true
15+
AllowShortLoopsOnASingleLine: true
16+
AlwaysBreakAfterDefinitionReturnType: None
17+
AlwaysBreakBeforeMultilineStrings: true
18+
AlwaysBreakTemplateDeclarations: true
19+
BinPackArguments: true
20+
BinPackParameters: true
21+
BreakBeforeBinaryOperators: None
22+
BreakBeforeBraces: Attach
23+
BreakBeforeTernaryOperators: true
24+
BreakConstructorInitializersBeforeComma: false
25+
ColumnLimit: 80
26+
CommentPragmas: '^ IWYU pragma:'
27+
ConstructorInitializerAllOnOneLineOrOnePerLine: true
28+
ConstructorInitializerIndentWidth: 4
29+
ContinuationIndentWidth: 4
30+
Cpp11BracedListStyle: false
31+
DerivePointerAlignment: true
32+
DisableFormat: false
33+
ExperimentalAutoDetectBinPacking: false
34+
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
35+
IndentCaseLabels: true
36+
IndentWidth: 4
37+
IndentWrappedFunctionNames: false
38+
KeepEmptyLinesAtTheStartOfBlocks: false
39+
MacroBlockBegin: ''
40+
MacroBlockEnd: ''
41+
MaxEmptyLinesToKeep: 1
42+
NamespaceIndentation: None
43+
ObjCBlockIndentWidth: 2
44+
ObjCSpaceAfterProperty: false
45+
ObjCSpaceBeforeProtocolList: false
46+
PenaltyBreakBeforeFirstCallParameter: 1
47+
PenaltyBreakComment: 300
48+
PenaltyBreakFirstLessLess: 120
49+
PenaltyBreakString: 1000
50+
PenaltyExcessCharacter: 1000000
51+
PenaltyReturnTypeOnItsOwnLine: 200
52+
PointerAlignment: Left
53+
SpaceAfterCStyleCast: false
54+
SpaceBeforeAssignmentOperators: true
55+
SpaceBeforeParens: ControlStatements
56+
SpaceInEmptyParentheses: false
57+
SpacesBeforeTrailingComments: 2
58+
SpacesInAngles: false
59+
SpacesInContainerLiterals: true
60+
SpacesInCStyleCastParentheses: false
61+
SpacesInParentheses: false
62+
SpacesInSquareBrackets: false
63+
Standard: Auto
64+
TabWidth: 8
65+
UseTab: Never
66+
...
67+

0 commit comments

Comments
 (0)