Skip to content

Commit 27c7e15

Browse files
redesign the API for compatibility with the named topics
1 parent 8b43af8 commit 27c7e15

File tree

7 files changed

+841
-2487
lines changed

7 files changed

+841
-2487
lines changed

.clang-format

Lines changed: 14 additions & 93 deletions
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,17 @@
1-
---
2-
Language: Cpp
3-
# BasedOnStyle: LLVM
4-
AccessModifierOffset: -4
5-
AlignAfterOpenBracket: Align
1+
Language: Cpp
2+
BasedOnStyle: Mozilla
3+
IndentWidth: 4
4+
ColumnLimit: 120
5+
Standard: c++20
6+
IndentExternBlock: NoIndent
7+
AlwaysBreakAfterDefinitionReturnType: None
8+
BreakAfterReturnType: None
9+
AllowShortFunctionsOnASingleLine: All
610
AlignConsecutiveAssignments: true
11+
AlignConsecutiveBitFields: true
712
AlignConsecutiveDeclarations: true
8-
AlignEscapedNewlines: Left
9-
AlignOperands: true
13+
AlignConsecutiveMacros: true
14+
AlignConsecutiveShortCaseStatements: { Enabled: true }
15+
AlignEscapedNewlines: LeftWithLastLine
1016
AlignTrailingComments: true
11-
AllowAllParametersOfDeclarationOnNextLine: false
12-
AllowShortBlocksOnASingleLine: false
13-
AllowShortCaseLabelsOnASingleLine: false
14-
AllowShortFunctionsOnASingleLine: Inline
15-
AllowShortIfStatementsOnASingleLine: Never
16-
AllowShortLoopsOnASingleLine: false
17-
AlwaysBreakAfterDefinitionReturnType: None
18-
AlwaysBreakAfterReturnType: None
19-
AlwaysBreakBeforeMultilineStrings: false
20-
AlwaysBreakTemplateDeclarations: Yes
21-
BinPackArguments: false
22-
BinPackParameters: false
23-
BraceWrapping:
24-
AfterCaseLabel: true
25-
AfterClass: true
26-
AfterControlStatement: true
27-
AfterEnum: true
28-
AfterFunction: true
29-
AfterNamespace: true
30-
AfterStruct: true
31-
AfterUnion: true
32-
BeforeCatch: true
33-
BeforeElse: true
34-
IndentBraces: false
35-
SplitEmptyFunction: false
36-
SplitEmptyRecord: false
37-
SplitEmptyNamespace: false
38-
AfterExternBlock: false # Keeps the contents un-indented.
39-
BreakBeforeBinaryOperators: None
40-
BreakBeforeBraces: Custom
41-
BreakBeforeTernaryOperators: true
42-
BreakConstructorInitializers: AfterColon
43-
# BreakInheritanceList: AfterColon
44-
BreakStringLiterals: true
45-
ColumnLimit: 120
46-
CommentPragmas: '^ (coverity|pragma:)'
47-
CompactNamespaces: false
48-
ConstructorInitializerAllOnOneLineOrOnePerLine: true
49-
ConstructorInitializerIndentWidth: 4
50-
ContinuationIndentWidth: 4
51-
Cpp11BracedListStyle: true
52-
DerivePointerAlignment: false
53-
DisableFormat: false
54-
ExperimentalAutoDetectBinPacking: false
55-
FixNamespaceComments: true
56-
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
57-
IncludeBlocks: Preserve
58-
IndentCaseLabels: false
59-
IndentPPDirectives: AfterHash
60-
IndentWidth: 4
61-
IndentWrappedFunctionNames: false
62-
KeepEmptyLinesAtTheStartOfBlocks: false
63-
MacroBlockBegin: ''
64-
MacroBlockEnd: ''
65-
MaxEmptyLinesToKeep: 1
66-
NamespaceIndentation: None
67-
PenaltyBreakAssignment: 2
68-
PenaltyBreakBeforeFirstCallParameter: 10000 # Raised intentionally; prefer breaking all
69-
PenaltyBreakComment: 300
70-
PenaltyBreakFirstLessLess: 120
71-
PenaltyBreakString: 1000
72-
PenaltyExcessCharacter: 1000000
73-
PenaltyReturnTypeOnItsOwnLine: 10000 # Raised intentionally because it hurts readability
74-
PointerAlignment: Left
75-
ReflowComments: true
76-
SortIncludes: false
77-
SortUsingDeclarations: false
78-
SpaceAfterCStyleCast: true
79-
SpaceAfterTemplateKeyword: true
80-
SpaceBeforeAssignmentOperators: true
81-
SpaceBeforeCpp11BracedList: false
82-
SpaceBeforeInheritanceColon: true
83-
SpaceBeforeParens: ControlStatements
84-
SpaceBeforeCtorInitializerColon: true
85-
SpaceBeforeRangeBasedForLoopColon: true
86-
SpaceInEmptyParentheses: false
87-
SpacesBeforeTrailingComments: 2
88-
SpacesInAngles: false
89-
SpacesInCStyleCastParentheses: false
90-
SpacesInContainerLiterals: false
91-
SpacesInParentheses: false
92-
SpacesInSquareBrackets: false
93-
Standard: Cpp11
94-
TabWidth: 8
95-
UseTab: Never
96-
...
17+
SortIncludes: false

.clang-tidy

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ Checks: >-
3030
-bugprone-casting-through-void,
3131
-misc-include-cleaner,
3232
-cppcoreguidelines-avoid-do-while,
33+
-*-magic-numbers,
3334
CheckOptions:
3435
- key: readability-function-cognitive-complexity.Threshold
3536
value: '99'

0 commit comments

Comments
 (0)