-
Notifications
You must be signed in to change notification settings - Fork 0
/
.clang-tidy
93 lines (69 loc) · 2.65 KB
/
.clang-tidy
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
87
88
89
90
91
92
UseColor: true
Checks: >
bugprone-*,
clang-analyzer-cplusplus*,
concurrency-*,
cppcoreguidelines-*,
misc-*,
modernize-*,
performance-*,
readability-*,
# Bazel does this for determinism,
-clang-diagnostic-builtin-macro-redefined,
# suppress due to assert,
-cppcoreguidelines-pro-bounds-array-to-pointer-decay,
# short names are fine for short lifetimes,
-readability-identifier-length,
# allow unused variables to be unnamed,
-readability-named-parameter,
# C-arrays necessary as function args,
-modernize-avoid-c-arrays,
# use iterators as abstractions, not pointers,
-readability-qualified-auto,
# it's okay for exceptions to escape main,
-bugprone-exception-escape,
# false positive with spaceship operator,
# https://reviews.llvm.org/D95714?id=320393,
# NOTE: still false positive with LLVM 17.0.2,
-modernize-use-nullptr,
# disable common aliases,
-cppcoreguidelines-avoid-c-arrays,
-cppcoreguidelines-avoid-magic-numbers,
-cppcoreguidelines-c-copy-assignment-signature,
-cppcoreguidelines-explicit-virtual-functions,
-cppcoreguidelines-non-private-member-variables-in-classes,
# disable EXTREMELY SLOW checks,
-bugprone-reserved-identifier,
-readability-identifier-naming,
-misc-confusable-identifiers,
# too many false positives,
-misc-include-cleaner,
# doesn't work with auto&,
-modernize-use-trailing-return-type,
# there are magic numbers in tests,
-readability-magic-numbers,
# hinnant style special member functions,
-cppcoreguidelines-special-member-functions,
# references are stored in short-lived objects that only live,
# until the end of the enclosing expression,
-cppcoreguidelines-avoid-const-or-ref-data-members,
# this library defines a DSL,
-misc-unconventional-assign-operator,
# false positives,
-readability-simplify-boolean-expr,
# false positives with overloaded operators (e.g. `^`),
-misc-redundant-expression,
# favor member init - reserving the non-init semantic as uninit (e.g. fundamental types, arrays),
-readability-redundant-member-init,
CheckOptions:
- key: misc-non-private-member-variables-in-classes.IgnoreClassesWithAllMemberVariablesBeingPublic
value: true
- key: performance-move-const-arg.CheckTriviallyCopyableMove
value: false
- key: readability-implicit-bool-conversion.AllowIntegerConditions
value : true
- key: readability-implicit-bool-conversion.AllowPointerConditions
value : true
# only lint files coming from this project
HeaderFilterRegex: '__main__/'
WarningsAsErrors: '*'