|
| 1 | +Checks: [ |
| 2 | + bugprone*, |
| 3 | + |
| 4 | + cert*, |
| 5 | + |
| 6 | + cppcoreguidelines*, |
| 7 | + # Need globals to communicate with interrupts |
| 8 | + -cppcoreguidelines-avoid-non-const-global-variables, |
| 9 | + # Covered by readability-magic-numbers |
| 10 | + -cppcoreguidelines-avoid-magic-numbers, |
| 11 | + # We use global aggregates to dispatch extern registers. |
| 12 | + # This cannot cause order-of-initialization problems because |
| 13 | + # registers are guaranteed to be initialized at reset. |
| 14 | + -cppcoreguidelines-interfaces-global-init, |
| 15 | + |
| 16 | + google*, |
| 17 | + |
| 18 | + hicpp*, |
| 19 | + # Bad warning: https://stackoverflow.com/questions/50399090/use-of-a-signed-integer-operand-with-a-binary-bitwise-operator-when-using-un |
| 20 | + -hicpp-signed-bitwise, |
| 21 | + |
| 22 | + llvm*, |
| 23 | + # We use a different include guard style |
| 24 | + -llvm-header-guard, |
| 25 | + |
| 26 | + misc*, |
| 27 | + |
| 28 | + modernize*, |
| 29 | + |
| 30 | + performance*, |
| 31 | + |
| 32 | + readability*, |
| 33 | +] |
| 34 | + |
| 35 | +CheckOptions: |
| 36 | + - key: bugprone-easily-swappable-parameters.ModelImplicitConversions |
| 37 | + value: false |
| 38 | + - key: readability-function-cognitive-complexity.Threshold |
| 39 | + value: '10' |
| 40 | + - key: readability-function-size.LineThreshold |
| 41 | + value: '80' |
| 42 | + |
| 43 | + - key: readability-identifier-length.MinimumParameterNameLength |
| 44 | + value: '1' |
| 45 | + - key: readability-identifier-length.IgnoredVariableNames |
| 46 | + value: '^dt|pu$' |
| 47 | + |
| 48 | + - key: readability-magic-numbers.IgnorePowersOf2IntegerValues |
| 49 | + value: 'true' |
| 50 | + - key: readability-magic-numbers.IgnoredIntegerValues |
| 51 | + value: '15;255;4095;65535;' |
| 52 | + |
| 53 | + # Empty loops should look like this: while (condition) continue; |
| 54 | + - key: readability-braces-around-statements.ShortStatementLines |
| 55 | + value: '1' |
| 56 | + - key: hicpp-braces-around-statements.ShortStatementLines |
| 57 | + value: '1' |
| 58 | + |
| 59 | + - key: readability-identifier-naming.EnumCase |
| 60 | + value: 'CamelCase' |
| 61 | + - key: readability-identifier-naming.FunctionCase |
| 62 | + value: 'lower_case' |
| 63 | + # Public functions have capitalized prefix |
| 64 | + - key: readability-identifier-naming.GlobalFunctionCase |
| 65 | + value: 'aNy_CasE' |
| 66 | + # Interrupt service routines |
| 67 | + - key: readability-identifier-naming.GlobalFunctionIgnoredRegexp |
| 68 | + value: '_[A-Z0-9]+Interrupt' |
| 69 | + - key: readability-identifier-naming.VariableCase |
| 70 | + value: 'lower_case' |
| 71 | + # Register names |
| 72 | + - key: readability-identifier-naming.VariableIgnoredRegexp |
| 73 | + value: '[A-Z][A-Z0-9]+(bits)?' |
| 74 | + - key: readability-identifier-naming.StructCase |
| 75 | + value: 'CamelCase' |
| 76 | + - key: readability-identifier-naming.TypedefCase |
| 77 | + value: 'CamelCase' |
| 78 | + - key: readability-identifier-naming.TypedefIgnoredRegexp |
| 79 | + value: '[A-Z]+_[a-zA-Z0-9]+' |
| 80 | + - key: readability-identifier-naming.EnumIgnoredRegexp |
| 81 | + value: '[A-Z]+_[a-zA-Z0-9]+' |
| 82 | + - key: readability-identifier-naming.StructIgnoredRegexp |
| 83 | + value: '[A-Z]+_[a-zA-Z0-9]+' |
| 84 | + - key: readability-identifier-naming.UnionIgnoredRegexp |
| 85 | + value: '[A-Z]+_[a-zA-Z0-9]+' |
| 86 | + - key: readability-identifier-naming.UnionCase |
| 87 | + value: 'CamelCase' |
| 88 | + - key: readability-identifier-naming.GlobalConstantCase |
| 89 | + value: 'UPPER_CASE' |
| 90 | + - key: readability-identifier-naming.GlobalConstantPrefix |
| 91 | + value: 'g_' |
| 92 | + - key: readability-identifier-naming.MacroDefinitionCase |
| 93 | + value: 'UPPER_CASE' |
| 94 | + |
| 95 | +FormatStyle: file |
| 96 | +SystemHeaders: false |
0 commit comments