# 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-implicit-bool-conversion,
                  -readability-magic-numbers,
                  -readability-else-after-return,
                  -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-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:           700
  - key:             readability-function-size.StatementThreshold
    value:           999999
  - key:             readability-function-size.BranchThreshold
    value:           170
  - key:             readability-function-size.ParameterThreshold
    value:           6
  - key:             readability-function-size.NestingThreshold
    value:           999999
  - key:             readability-function-size.VariableThreshold
    value:           80
...
