Skip to content

Commit c689940

Browse files
committed
Add .clang-format file
1 parent bb0d568 commit c689940

File tree

1 file changed

+208
-0
lines changed

1 file changed

+208
-0
lines changed

.clang-format

Lines changed: 208 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,208 @@
1+
---
2+
Language: Cpp
3+
BasedOnStyle: LLVM
4+
# AccessModifierOffset: -2
5+
AccessModifierOffset: -4
6+
# AlignAfterOpenBracket: Align
7+
# AlignArrayOfStructures: None
8+
AlignArrayOfStructures: Left
9+
# AlignConsecutiveMacros: None
10+
AlignConsecutiveMacros: Consecutive
11+
# AlignConsecutiveAssignments: None
12+
AlignConsecutiveAssignments: Consecutive
13+
# AlignConsecutiveBitFields: None
14+
# AlignConsecutiveDeclarations: None
15+
# AlignEscapedNewlines: Right
16+
AlignEscapedNewlines: Left
17+
# AlignOperands: Align
18+
# AlignTrailingComments: true
19+
AlignTrailingComments: false
20+
# AllowAllArgumentsOnNextLine: true
21+
AllowAllArgumentsOnNextLine: false
22+
# AllowAllParametersOfDeclarationOnNextLine: true
23+
AllowAllParametersOfDeclarationOnNextLine: false
24+
# AllowShortEnumsOnASingleLine: true
25+
# AllowShortBlocksOnASingleLine: Never
26+
AllowShortBlocksOnASingleLine: Empty
27+
# AllowShortCaseLabelsOnASingleLine: false
28+
# AllowShortFunctionsOnASingleLine: All
29+
# AllowShortLambdasOnASingleLine: All
30+
# AllowShortIfStatementsOnASingleLine: Never
31+
# AllowShortLoopsOnASingleLine: false
32+
# AlwaysBreakAfterDefinitionReturnType: None
33+
# AlwaysBreakAfterReturnType: None
34+
# AlwaysBreakBeforeMultilineStrings: false
35+
# AlwaysBreakTemplateDeclarations: MultiLine
36+
AlwaysBreakTemplateDeclarations: Yes
37+
# AttributeMacros:
38+
# - __capability
39+
# BinPackArguments: true
40+
BinPackArguments: false
41+
# BinPackParameters: true
42+
BinPackParameters: false
43+
# BraceWrapping:
44+
# AfterCaseLabel: false
45+
# AfterClass: false
46+
# AfterControlStatement: Never
47+
# AfterEnum: false
48+
# AfterFunction: false
49+
# AfterNamespace: false
50+
# AfterObjCDeclaration: false
51+
# AfterStruct: false
52+
# AfterUnion: false
53+
# AfterExternBlock: false
54+
# BeforeCatch: false
55+
# BeforeElse: false
56+
# BeforeLambdaBody: false
57+
# BeforeWhile: false
58+
# IndentBraces: false
59+
# SplitEmptyFunction: true
60+
# SplitEmptyRecord: true
61+
# SplitEmptyNamespace: true
62+
# BreakBeforeBinaryOperators: None
63+
# BreakBeforeConceptDeclarations: true
64+
# BreakBeforeBraces: Attach
65+
# BreakBeforeInheritanceComma: false
66+
# BreakInheritanceList: BeforeColon
67+
# BreakBeforeTernaryOperators: true
68+
# BreakConstructorInitializersBeforeComma: false
69+
# BreakConstructorInitializers: BeforeColon
70+
# BreakAfterJavaFieldAnnotations: false
71+
# BreakStringLiterals: true
72+
# ColumnLimit: 80
73+
ColumnLimit: 120
74+
# CommentPragmas: '^ IWYU pragma:'
75+
# QualifierAlignment: Leave
76+
# CompactNamespaces: false
77+
# ConstructorInitializerIndentWidth: 4
78+
# ContinuationIndentWidth: 4
79+
# Cpp11BracedListStyle: true
80+
# DeriveLineEnding: true
81+
# DerivePointerAlignment: false
82+
# DisableFormat: false
83+
# EmptyLineAfterAccessModifier: Never
84+
# EmptyLineBeforeAccessModifier: LogicalBlock
85+
# ExperimentalAutoDetectBinPacking: false
86+
# PackConstructorInitializers: BinPack
87+
# BasedOnStyle: ''
88+
# ConstructorInitializerAllOnOneLineOrOnePerLine: false
89+
# AllowAllConstructorInitializersOnNextLine: true
90+
# FixNamespaceComments: true
91+
# ForEachMacros:
92+
# - foreach
93+
# - Q_FOREACH
94+
# - BOOST_FOREACH
95+
# IfMacros:
96+
# - KJ_IF_MAYBE
97+
# IncludeBlocks: Preserve
98+
# IncludeCategories:
99+
# - Regex: '^"(llvm|llvm-c|clang|clang-c)/'
100+
# Priority: 2
101+
# SortPriority: 0
102+
# CaseSensitive: false
103+
# - Regex: '^(<|"(gtest|gmock|isl|json)/)'
104+
# Priority: 3
105+
# SortPriority: 0
106+
# CaseSensitive: false
107+
# - Regex: '.*'
108+
# Priority: 1
109+
# SortPriority: 0
110+
# CaseSensitive: false
111+
# IncludeIsMainRegex: '(Test)?$'
112+
# IncludeIsMainSourceRegex: ''
113+
# IndentAccessModifiers: false
114+
# IndentCaseLabels: false
115+
# IndentCaseBlocks: false
116+
# IndentGotoLabels: true
117+
# IndentPPDirectives: None
118+
# IndentExternBlock: AfterExternBlock
119+
# IndentRequires: false
120+
# IndentWidth: 2
121+
IndentWidth: 4
122+
# IndentWrappedFunctionNames: false
123+
# InsertTrailingCommas: None
124+
# JavaScriptQuotes: Leave
125+
# JavaScriptWrapImports: true
126+
# KeepEmptyLinesAtTheStartOfBlocks: true
127+
# LambdaBodyIndentation: Signature
128+
# MacroBlockBegin: ''
129+
# MacroBlockEnd: ''
130+
# MaxEmptyLinesToKeep: 1
131+
# NamespaceIndentation: None
132+
# ObjCBinPackProtocolList: Auto
133+
# ObjCBlockIndentWidth: 2
134+
# ObjCBreakBeforeNestedBlockParam: true
135+
# ObjCSpaceAfterProperty: false
136+
# ObjCSpaceBeforeProtocolList: true
137+
# PenaltyBreakAssignment: 2
138+
# PenaltyBreakBeforeFirstCallParameter: 19
139+
# PenaltyBreakComment: 300
140+
# PenaltyBreakFirstLessLess: 120
141+
# PenaltyBreakOpenParenthesis: 0
142+
# PenaltyBreakString: 1000
143+
# PenaltyBreakTemplateDeclaration: 10
144+
# PenaltyExcessCharacter: 1000000
145+
# PenaltyReturnTypeOnItsOwnLine: 60
146+
# PenaltyIndentedWhitespace: 0
147+
# PointerAlignment: Right
148+
PointerAlignment: Left
149+
# PPIndentWidth: -1
150+
# ReferenceAlignment: Pointer
151+
# ReflowComments: true
152+
# RemoveBracesLLVM: false
153+
# SeparateDefinitionBlocks: Leave
154+
# ShortNamespaceLines: 1
155+
# SortIncludes: CaseSensitive
156+
# SortJavaStaticImport: Before
157+
# SortUsingDeclarations: true
158+
# SpaceAfterCStyleCast: false
159+
SpaceAfterCStyleCast: true
160+
# SpaceAfterLogicalNot: false
161+
# SpaceAfterTemplateKeyword: true
162+
# SpaceBeforeAssignmentOperators: true
163+
# SpaceBeforeCaseColon: false
164+
# SpaceBeforeCpp11BracedList: false
165+
# SpaceBeforeCtorInitializerColon: true
166+
# SpaceBeforeInheritanceColon: true
167+
# SpaceBeforeParens: ControlStatements
168+
# SpaceBeforeParensOptions:
169+
# AfterControlStatements: true
170+
# AfterForeachMacros: true
171+
# AfterFunctionDefinitionName: false
172+
# AfterFunctionDeclarationName: false
173+
# AfterIfMacros: true
174+
# AfterOverloadedOperator: false
175+
# BeforeNonEmptyParentheses: false
176+
# SpaceAroundPointerQualifiers: Default
177+
# SpaceBeforeRangeBasedForLoopColon: true
178+
# SpaceInEmptyBlock: false
179+
# SpaceInEmptyParentheses: false
180+
# SpacesBeforeTrailingComments: 1
181+
SpacesBeforeTrailingComments: 2
182+
# SpacesInAngles: Never
183+
# SpacesInConditionalStatement: false
184+
# SpacesInContainerLiterals: true
185+
# SpacesInCStyleCastParentheses: false
186+
# SpacesInLineCommentPrefix:
187+
# Minimum: 1
188+
# Maximum: -1
189+
# SpacesInParentheses: false
190+
# SpacesInSquareBrackets: false
191+
# SpaceBeforeSquareBrackets: false
192+
# BitFieldColonSpacing: Both
193+
# Standard: Latest
194+
# StatementAttributeLikeMacros:
195+
# - Q_EMIT
196+
# StatementMacros:
197+
# - Q_UNUSED
198+
# - QT_REQUIRE_VERSION
199+
# TabWidth: 8
200+
# UseCRLF: false
201+
# UseTab: Never
202+
# WhitespaceSensitiveMacros:
203+
# - STRINGIZE
204+
# - PP_STRINGIZE
205+
# - BOOST_PP_STRINGIZE
206+
# - NS_SWIFT_NAME
207+
# - CF_SWIFT_NAME
208+
...

0 commit comments

Comments
 (0)