forked from organicmaps/organicmaps
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.clang-format
453 lines (366 loc) · 12.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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
# Configuration file for clang-format, based on docs/CPP_STYLE.md.
---
BasedOnStyle: Google
IndentWidth: 2
BreakBeforeBraces: Allman
ColumnLimit: 100
---
Language: Cpp
AccessModifierOffset: -2
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: true
AllowShortFunctionsOnASingleLine: true
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
BreakConstructorInitializersBeforeComma: true
ConstructorInitializerIndentWidth: 2
DerivePointerAlignment: false
IndentCaseLabels: false
NamespaceIndentation: None
PointerAlignment: Middle
SortIncludes: true
Standard: Cpp11
IncludeBlocks: Regroup
IncludeCategories:
# Tests --------------------------------------------------------------------------------------------
- Regex: '^"track_analyzing/track_analyzing_tests/'
Priority: 4730
- Regex: '^"poly_borders/poly_borders_tests/'
Priority: 4740
- Regex: '^"generator/generator_integration_tests/'
Priority: 4750
- Regex: '^"generator/generator_tests/'
Priority: 4751
- Regex: '^"generator/mwm_diff_tests/'
Priority: 4752
- Regex: '^"map/style_tests/'
Priority: 4760
- Regex: '^"map/mwm_tests/'
Priority: 4761
- Regex: '^"map/map_tests/'
Priority: 4762
- Regex: '^"map/map_integration_tests/'
Priority: 4763
- Regex: '^"ge0/ge0_tests/'
Priority: 4765
- Regex: '^"openlr/openlr_tests/'
Priority: 4770
- Regex: '^"descriptions/descriptions_tests/'
Priority: 4790
- Regex: '^"ugc/ugc_tests'
Priority: 4810
- Regex: '^"search/search_integration_tests/'
Priority: 4820
- Regex: '^"search/search_tests/'
Priority: 4821
- Regex: '^"search/search_quality/search_quality_tests/'
Priority: 4822
- Regex: '^"drape_frontend/drape_frontend_tests/'
Priority: 4830
- Regex: '^"routing/routing_tests/'
Priority: 4840
- Regex: '^"routing/routing_integration_tests/'
Priority: 4841
- Regex: '^"routing/routing_quality/routing_quality_tests/'
Priority: 4842
- Regex: '^"routing/routing_consistency_tests/'
Priority: 4843
- Regex: '^"routing/routing_benchmarks/'
Priority: 4844
- Regex: '^"kml/kml_tests'
Priority: 4850
- Regex: '^"tracking/tracking_tests/'
Priority: 4860
- Regex: '^"partners_api/partners_api_tests/'
Priority: 4870
- Regex: '^"traffic/traffic_tests/'
Priority: 4880
- Regex: '^"storage/storage_tests/'
Priority: 4890
- Regex: '^"storage/storage_integration_tests/'
Priority: 4891
- Regex: '^"editor/editor_tests/'
Priority: 4900
- Regex: '^"editor/osm_auth_tests/'
Priority: 4910
- Regex: '^"drape/drape_tests/'
Priority: 4920
- Regex: '^"transit/transit_tests'
Priority: 4930
- Regex: '^"routing_common/routing_common_tests/'
Priority: 4940
- Regex: '^"indexer/indexer_tests/'
Priority: 4950
- Regex: '^"platform/platform_tests/'
Priority: 4960
- Regex: '^"coding/coding_tests/'
Priority: 4970
- Regex: '^"geometry/geometry_tests/'
Priority: 4980
- Regex: '^"base/base_tests/'
Priority: 4990
- Regex: '^"testing/'
Priority: 5000
# Binaries (tools) ---------------------------------------------------------------------------------
- Regex: '^"openlr/openlr_match_quality/openlr_assessment_tool/'
Priority: 18908
- Regex: '^"search/search_quality/assessment_tool/'
Priority: 18909
- Regex: '^"qt/'
Priority: 18910
- Regex: '^"track_analyzing/track_analyzer/'
Priority: 19000
- Regex: '^"feature_list/'
Priority: 19100
- Regex: '^"generator/booking_quality_check/'
Priority: 19206
- Regex: '^"generator/complex_generator/'
Priority: 19207
- Regex: '^"generator/feature_segments_checker/'
Priority: 19208
- Regex: '^"generator/srtm_coverage_checker/'
Priority: 19209
- Regex: '^"generator/generator_tool/'
Priority: 19210
- Regex: '^"map/extrapolation_benchmark/'
Priority: 19309
- Regex: '^"map/benchmark_tool/'
Priority: 19310
- Regex: '^"openlr/openlr_stat/'
Priority: 19400
- Regex: '^"mapshot/'
Priority: 19500
- Regex: '^"search/search_quality/booking_dataset_generator/'
Priority: 19707
- Regex: '^"search/search_quality/features_collector_tool/'
Priority: 19708
- Regex: '^"search/search_quality/samples_generation_tool/'
Priority: 19709
- Regex: '^"search/search_quality/search_quality_tool/'
Priority: 19710
- Regex: '^"track_generator/'
Priority: 19800
- Regex: '^"routing/routing_quality/routing_quality_tool/'
Priority: 19909
- Regex: '^"routing/routes_builder/routes_builder_tool/'
Priority: 19910
- Regex: '^"skin_generator/'
Priority: 20000
# Libraries ----------------------------------------------------------------------------------------
- Regex: '^"poly_borders/'
Priority: 46700
- Regex: '^"track_analyzing/'
Priority: 46800
- Regex: '^"generator/mwm_diff/pymwm_diff/'
Priority: 46907
- Regex: '^"generator/mwm_diff/'
Priority: 46908
- Regex: '^"generator/generator_tests_support/'
Priority: 46909
- Regex: '^"generator/'
Priority: 46910
- Regex: '^"map/'
Priority: 47000
- Regex: '^"ge0/'
Priority: 47050
- Regex: '^"openlr/'
Priority: 47100
- Regex: '^"descriptions/'
Priority: 47300
- Regex: '^"search/search_quality/'
Priority: 47407
- Regex: '^"search/search_tests_support/'
Priority: 47408
- Regex: '^"search/pysearch/'
Priority: 47409
- Regex: '^"search/'
Priority: 47410
- Regex: '^"ugc/'
Priority: 47500
- Regex: '^"track_generator/pytrack_generator/'
Priority: 47600
- Regex: '^"routing/routing_quality/api/'
Priority: 47707
- Regex: '^"routing/routing_quality/'
Priority: 47708
- Regex: '^"routing/routes_builder/'
Priority: 47709
- Regex: '^"routing/'
Priority: 47710
- Regex: '^"tracking/pytracking/'
Priority: 47809
- Regex: '^"tracking/'
Priority: 47810
- Regex: '^"partners_api/'
Priority: 47900
- Regex: '^"traffic/pytraffic/'
Priority: 48109
- Regex: '^"traffic/'
Priority: 48110
- Regex: '^"storage/'
Priority: 48200
- Regex: '^"editor/editor_tests_support/'
Priority: 48309
- Regex: '^"editor/'
Priority: 48310
- Regex: '^"software_renderer/'
Priority: 48400
- Regex: '^"drape_frontend/'
Priority: 48500
- Regex: '^"shaders/'
Priority: 48600
- Regex: '^"drape/'
Priority: 48700
- Regex: '^"qt_tstfrm/'
Priority: 48800
- Regex: '^"kml/pykmlib/'
Priority: 48909
- Regex: '^"kml/'
Priority: 48910
- Regex: '^"transit/'
Priority: 49000
- Regex: '^"routing_common/'
Priority: 49100
- Regex: '^"indexer/'
Priority: 49200
- Regex: '^"platform/platform_tests_support/'
Priority: 49409
- Regex: '^"platform/'
Priority: 49410
- Regex: '^"coding/'
Priority: 49500
- Regex: '^"geometry/'
Priority: 49600
- Regex: '^"base/'
Priority: 49700
- Regex: '^"pyhelpers/'
Priority: 49800
- Regex: '^"com/mapswithme/util/'
Priority: 49840
- Regex: '^"com/mapswithme/maps/'
Priority: 49850
- Regex: '^"com/mapswithme/platform/'
Priority: 49860
- Regex: '^"com/mapswithme/opengl/'
Priority: 49870
- Regex: '^"com/mapswithme/vulkan/'
Priority: 49880
- Regex: '^"com/mapswithme/core/'
Priority: 49890
- Regex: '^"private\.h"$'
Priority: 49900
- Regex: '^"std/'
Priority: 50000
- Regex: '^"defines\.hpp"$'
Priority: 50100
- Regex: '^<Qt.*>$'
Priority: 50140
- Regex: '^<jni.h>$'
Priority: 50180
- Regex: '^<.*>$'
Priority: 50200
- Regex: '^"(3party/boost|boost)/'
Priority: 50300
- Regex: '^<boost'
Priority: 50300
- Regex: '^"3party/.*'
Priority: 50400
- Regex: '^"build_version\.hpp"$'
Priority: 99999
---
Language: Java
BreakAfterJavaFieldAnnotations: true
---
Language: ObjC
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: Left
AlignOperands: true
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: Yes
BinPackArguments: true
BinPackParameters: true
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Attach
BreakBeforeInheritanceComma: false
BreakInheritanceList: AfterColon
BreakBeforeTernaryOperators: true
BreakStringLiterals: true
ColumnLimit: 120
CompactNamespaces: false
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 2
Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat: false
ExperimentalAutoDetectBinPacking: false
FixNamespaceComments: true
ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^<.*\.h>'
Priority: 1
- Regex: '^<.*'
Priority: 2
- Regex: '.*'
Priority: 3
IncludeIsMainRegex: '([-_](test|unittest))?$'
IndentCaseLabels: true
IndentPPDirectives: None
IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: false
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBinPackProtocolList: Never
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 1
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Right
ReflowComments: true
SortIncludes: true
SortUsingDeclarations: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeParens: ControlStatements
SpaceBeforeRangeBasedForLoopColon: true
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 2
SpacesInAngles: false
SpacesInContainerLiterals: false
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Auto
TabWidth: 8
UseTab: Never