clang-tidy-11 fixes for topology, gpu_utils, and selection
[alexxy/gromacs.git] / src / gromacs / selection / .clang-tidy
1 # List of rationales for check suppressions (where known).
2 # This have to precede the list because inline comments are not
3 # supported by clang-tidy.
4 #
5 #         -cppcoreguidelines-non-private-member-variables-in-classes,
6 #         -misc-non-private-member-variables-in-classes,
7 # We intend a gradual transition to conform to this guideline, but it
8 # is not practical to implement yet.
9 #
10 #         -readability-isolate-declaration,
11 # Declarations like "int a, b;" are readable. Some forms are not, and
12 # those might reasonably be suggested against during code review.
13 #
14 #         -cppcoreguidelines-avoid-c-arrays,
15 # C arrays are still necessary in many places with legacy code
16 #
17 #         -cppcoreguidelines-avoid-magic-numbers,
18 #         -readability-magic-numbers,
19 # We have many legitimate use cases for magic numbers
20 #
21 #         -cppcoreguidelines-macro-usage,
22 # We do use too many macros, and we should fix many of them, but there
23 # is no reasonable way to suppress the check e.g. in src/config.h and
24 # configuring the build is a major legitimate use of macros.
25 #
26 #         -cppcoreguidelines-narrowing-conversions,
27 #         -bugprone-narrowing-conversions
28 # We have many cases where int is converted to float and we don't care
29 # enough about such potential loss of precision to use explicit casts
30 # in large numbers of places.
31 #
32 #         -google-readability-avoid-underscore-in-googletest-name
33 # We need to use underscores for readability for our legacy types
34 # and command-line parameter names
35 #
36 #         -misc-no-recursion
37 # We have way too many functions and methods relying on recursion
38 #
39 #         -bugprone-reserved-identifier
40 # Quite a large number of functions use the _FName style for naming
41 #
42 #         -cppcoreguidelines-avoid-non-const-global-variables
43 # The selection code has a large amount of static or exported non-const
44 # variables that are out of scope for quick rework
45 Checks:  clang-diagnostic-*,-clang-analyzer-*,-clang-analyzer-security.insecureAPI.strcpy,
46          bugprone-*,misc-*,readability-*,performance-*,mpi-*,
47          -readability-inconsistent-declaration-parameter-name,
48          -readability-function-size,-readability-else-after-return,
49          modernize-use-nullptr,modernize-use-emplace,
50          modernize-make-unique,modernize-make-shared,
51          modernize-avoid-bind,
52          modernize-use-override,
53          modernize-redundant-void-arg,modernize-use-bool-literals,
54          cppcoreguidelines-*,-cppcoreguidelines-pro-*,-cppcoreguidelines-owning-memory,
55          -cppcoreguidelines-no-malloc,-cppcoreguidelines-special-member-functions,
56          -cppcoreguidelines-avoid-goto,
57          google-*,-google-build-using-namespace,-google-explicit-constructor,
58          -google-readability-function-size,-google-readability-todo,-google-runtime-int,
59          -cppcoreguidelines-non-private-member-variables-in-classes,
60          -misc-non-private-member-variables-in-classes,
61          -readability-isolate-declaration,
62          -cppcoreguidelines-avoid-c-arrays,
63          -cppcoreguidelines-avoid-magic-numbers,
64          -readability-magic-numbers,
65          -cppcoreguidelines-macro-usage,
66          -cppcoreguidelines-narrowing-conversions,
67          -bugprone-narrowing-conversions,
68          -google-readability-avoid-underscore-in-googletest-name,
69          -cppcoreguidelines-init-variables,
70          -misc-no-recursion, -bugprone-reserved-identifier,
71          -cppcoreguidelines-avoid-non-const-global-variables
72 HeaderFilterRegex: .*
73 CheckOptions:
74   - key:           cppcoreguidelines-special-member-functions.AllowSoleDefaultDtor
75     value:         1
76   - key:           modernize-make-unique.IncludeStyle
77     value:         google
78   - key:           modernize-make-shared.IncludeStyle
79     value:         google
80   - key:           readability-implicit-bool-conversion.AllowIntegerConditions
81     value:         1
82   - key:           readability-implicit-bool-conversion.AllowPointerConditions
83     value:         1
84   - key:           bugprone-dangling-handle.HandleClasses
85     value:         std::basic_string_view; nonstd::sv_lite::basic_string_view
86 # Permit passing shard pointers by value for sink parameters
87   - key:           performance-unnecessary-copy-initialization.AllowedTypes
88     value:         shared_ptr
89   - key:           performance-unnecessary-value-param.AllowedTypes
90     value:         shared_ptr