forked from CleverRaven/Cataclysm-DDA
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.clang-tidy
87 lines (85 loc) · 2.77 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
# Enable some categories of checks and then disable individual ones.
# The disabled checks that appear as part of the initial alphabetical section
# enabling categories (e.g. cert-err58-cpp) are ones that do not make sense for
# this codebase and we do not intend to fix. The disabled checks appearing
# thereafter in a separate alphabetical list have yet to be triaged. We may
# fix their errors or recategorise them as checks we don't care about.
#
# Comments on the checks we have decided are not worthwhile:
#
# * cert-dcl21-cpp (postfix operator++ and operator-- should return const objects)
# This is an unconventional code style, and conflicts with
# readability-const-return-type.
#
# * cert-env33-c (calls to system, popen)
# Unlikely to catch bugs, and using system is convenient for portability.
#
# * cert-err58-cpp (exceptions from static variable declarations)
# We have lots of memory allocations in static variable declarations, and
# that's fine.
#
# * modernize-use-auto
# We prefer an almost-always-avoid-auto style.
#
# * modernize-use-trailing-return-type
# An arbitrary style convention we haven't adopted.
#
# * readability-braces-around-statements
# Covered by astyle and buggy in clang-tidy 8. Can enable once we have a newer
# clang-tidy.
Checks: "\
bugprone-*,\
cata-*,\
cert-*,\
-cert-dcl21-cpp,\
-cert-env33-c,\
-cert-err58-cpp,\
clang-diagnostic-*,\
cppcoreguidelines-slicing,\
google-explicit-constructor,\
llvm-namespace-comment,\
misc-*,\
modernize-*,\
-modernize-use-auto,\
-modernize-use-trailing-return-type,\
performance-*,\
readability-*,\
-readability-braces-around-statements,\
-bugprone-infinite-loop,\
-bugprone-misplaced-widening-cast,\
-bugprone-narrowing-conversions,\
-clang-analyzer-core.CallAndMessage,\
-clang-analyzer-deadcode.DeadStores,\
-misc-misplaced-const,\
-misc-no-recursion,\
-misc-non-private-member-variables-in-classes,\
-modernize-avoid-bind,\
-modernize-avoid-c-arrays,\
-modernize-pass-by-value,\
-modernize-return-braced-init-list,\
-modernize-use-default-member-init,\
-modernize-use-override,\
-performance-no-automatic-move,\
-performance-trivially-destructible,\
-performance-unnecessary-value-param,\
-readability-convert-member-functions-to-static,\
-readability-else-after-return,\
-readability-function-cognitive-complexity,\
-readability-implicit-bool-conversion,\
-readability-magic-numbers,\
-readability-make-member-function-const,\
-readability-named-parameter,\
-readability-redundant-access-specifiers,\
-readability-use-anyofallof,\
"
WarningsAsErrors: '*'
HeaderFilterRegex: '(src|test|tools).*'
FormatStyle: none
CheckOptions:
- key: cata-text-style.EscapeUnicode
value: 0
- key: cert-oop54-cpp.WarnOnlyIfThisHasSuspiciousField
value: true
- key: readability-uppercase-literal-suffix.NewSuffixes
value: 'L;UL;LL;ULL'
# vim:tw=0