summaryrefslogtreecommitdiff
path: root/src/.clang-tidy
blob: e0a7e652458d13678fb0eb090eeae18a0fa0ad1e (plain)
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
# This .clang-tidy file is used by CI to ensure that commits do not worsen the
# codebase. The checks and values below are the minimum standard for new code.
# (Without claiming that they are 100% correct. They can be modified on demand!)
# If you want to improve the codebase try enabling some additional checks or
# playing with the configuration values.
#
# Some checks are highly style dependent. The goal is NOT to activate all of
# them.

---
Checks:          '-*,
                  readability-*,
                  -readability-convert-member-functions-to-static,
                  -readability-implicit-bool-conversion,
                  -readability-magic-numbers,
                  -readability-else-after-return,
                  -readability-function-cognitive-complexity,
                  -readability-named-parameter,
                  -readability-qualified-auto,
                  -readability-redundant-declaration,
                  performance-*,
                  -performance-unnecessary-value-param,
                  modernize-*,
                  -modernize-avoid-c-arrays,
                  -modernize-pass-by-value,
                  -modernize-return-braced-init-list,
                  -modernize-use-auto,
                  -modernize-use-default-member-init,
                  -modernize-use-nodiscard,
                  -modernize-use-trailing-return-type,
                  cppcoreguidelines-*,
                  -cppcoreguidelines-pro-bounds-array-to-pointer-decay,
                  -cppcoreguidelines-pro-type-vararg,
                  -cppcoreguidelines-owning-memory,
                  -cppcoreguidelines-avoid-magic-numbers,
                  -cppcoreguidelines-avoid-non-const-global-variables,
                  -cppcoreguidelines-const-correctness,
                  -cppcoreguidelines-pro-bounds-pointer-arithmetic,
                  -cppcoreguidelines-no-malloc,
                  -cppcoreguidelines-init-variables,
                  -cppcoreguidelines-avoid-c-arrays,
                  -cppcoreguidelines-pro-bounds-constant-array-index,
                  -cppcoreguidelines-pro-type-member-init,
                  -cppcoreguidelines-macro-usage,
                  -cppcoreguidelines-pro-type-const-cast,
                  -cppcoreguidelines-pro-type-reinterpret-cast,
                  -cppcoreguidelines-pro-type-union-access,
                  -cppcoreguidelines-narrowing-conversions,
                  -cppcoreguidelines-non-private-member-variables-in-classes,
                  -cppcoreguidelines-special-member-functions,
                  bugprone-*,
                  -bugprone-signed-char-misuse,
                  -bugprone-branch-clone,
                  -bugprone-narrowing-conversions,
                  cert-*,
                  -cert-err34-c,
                  -cert-dcl50-cpp,
                  -cert-dcl58-cpp,
                  -cert-err58-cpp,
                  clang-diagnostic-*,
                  clang-analyzer-*,
                  -clang-analyzer-alpha*,
                  -clang-analyzer-valist.Uninitialized,
                  -clang-analyzer-optin.performance.Padding'
WarningsAsErrors: '*'
# Only include headers directly in src.
HeaderFilterRegex: 'src/[^/]*$'
CheckOptions:
  # Always add braces (added here just in case Clang-Tidy default changes).
  - key:             readability-braces-around-statements.ShortStatementLines
    value:           0

  # If you hit a limit, please consider changing the code instead of the limit.
  - key:             readability-function-size.LineThreshold
    value:           999999
  - key:             readability-function-size.StatementThreshold
    value:           999999
  - key:             readability-function-size.BranchThreshold
    value:           999999
  - key:             readability-function-size.ParameterThreshold
    value:           7
  - key:             readability-function-size.NestingThreshold
    value:           999999
  - key:             readability-function-size.VariableThreshold
    value:           80
...