xref: /openbmc/dbus-sensors/.clang-tidy (revision f3fd5248)
1Checks: '
2-*,
3boost-use-to-string,
4bugprone-argument-comment,
5bugprone-assignment-in-if-condition,
6bugprone-assert-side-effect,
7bugprone-bad-signal-to-kill-thread,
8bugprone-bool-pointer-implicit-conversion,
9bugprone-branch-clone,
10bugprone-copy-constructor-init,
11bugprone-dangling-handle,
12bugprone-dynamic-static-initializers,
13bugprone-fold-init-type,
14bugprone-forward-declaration-namespace,
15bugprone-forwarding-reference-overload,
16bugprone-implicit-widening-of-multiplication-result,
17bugprone-inaccurate-erase,
18bugprone-incorrect-roundings,
19bugprone-infinite-loop,
20bugprone-integer-division,
21bugprone-lambda-function-name,
22bugprone-macro-parentheses,
23bugprone-macro-repeated-side-effects,
24bugprone-misplaced-operator-in-strlen-in-alloc,
25bugprone-misplaced-pointer-arithmetic-in-alloc,
26bugprone-misplaced-widening-cast,
27bugprone-move-forwarding-reference,
28bugprone-multiple-statement-macro,
29bugprone-no-escape,
30bugprone-not-null-terminated-result,
31bugprone-parent-virtual-call,
32bugprone-posix-return,
33bugprone-redundant-branch-condition,
34bugprone-reserved-identifier,
35bugprone-signal-handler,
36bugprone-signed-char-misuse,
37bugprone-sizeof-container,
38bugprone-sizeof-expression,
39bugprone-spuriously-wake-up-functions,
40bugprone-string-constructor,
41bugprone-string-integer-assignment,
42bugprone-string-literal-with-embedded-nul,
43bugprone-suspicious-enum-usage,
44bugprone-suspicious-include,
45bugprone-suspicious-memset-usage,
46bugprone-suspicious-missing-comma,
47bugprone-suspicious-semicolon,
48bugprone-suspicious-string-compare,
49bugprone-swapped-arguments,
50bugprone-terminating-continue,
51bugprone-throw-keyword-missing,
52bugprone-too-small-loop-variable,
53bugprone-undefined-memory-manipulation,
54bugprone-undelegated-constructor,
55bugprone-unhandled-exception-at-new,
56bugprone-unhandled-self-assignment,
57bugprone-unused-local-non-trivial-variable,
58bugprone-unused-raii,
59bugprone-unused-return-value,
60bugprone-use-after-move,
61bugprone-virtual-near-miss,
62cert-con36-c,
63cert-con54-cpp,
64cert-dcl03-c,
65cert-dcl16-c,
66cert-dcl21-cpp,
67cert-dcl50-cpp,
68cert-dcl54-cpp,
69cert-dcl58-cpp,
70cert-dcl59-cpp,
71cert-env33-c,
72cert-err09-cpp,
73cert-err34-c,
74cert-err52-cpp,
75cert-err60-cpp,
76cert-err61-cpp,
77cert-fio38-c,
78cert-flp30-c,
79cert-mem57-cpp,
80cert-msc30-c,
81cert-msc32-c,
82cert-msc50-cpp,
83cert-msc51-cpp,
84cert-oop11-cpp,
85cert-oop54-cpp,
86cert-oop57-cpp,
87cert-oop58-cpp,
88cert-pos44-c,
89cert-pos47-c,
90cert-sig30-c,
91cert-str34-c,
92clang-analyzer-apiModeling.StdCLibraryFunctions,
93clang-analyzer-apiModeling.TrustNonnull,
94clang-analyzer-apiModeling.google.GTest,
95clang-analyzer-apiModeling.llvm.CastValue,
96clang-analyzer-apiModeling.llvm.ReturnValue,
97clang-analyzer-core.CallAndMessageModeling,
98clang-analyzer-core.DivideZero,
99clang-analyzer-core.DynamicTypePropagation,
100clang-analyzer-core.NonNullParamChecker,
101clang-analyzer-core.NonnilStringConstants,
102clang-analyzer-core.NullDereference,
103clang-analyzer-core.StackAddrEscapeBase,
104clang-analyzer-core.StackAddressEscape,
105clang-analyzer-core.UndefinedBinaryOperatorResult,
106clang-analyzer-core.VLASize,
107clang-analyzer-core.builtin.BuiltinFunctions,
108clang-analyzer-core.builtin.NoReturnFunctions,
109clang-analyzer-core.uninitialized.ArraySubscript,
110clang-analyzer-core.uninitialized.Assign,
111clang-analyzer-core.uninitialized.Branch,
112clang-analyzer-core.uninitialized.CapturedBlockVariable,
113clang-analyzer-core.uninitialized.UndefReturn,
114clang-analyzer-cplusplus.InnerPointer,
115clang-analyzer-cplusplus.Move,
116clang-analyzer-cplusplus.NewDelete,
117clang-analyzer-cplusplus.NewDeleteLeaks,
118clang-analyzer-cplusplus.PlacementNew,
119clang-analyzer-cplusplus.PureVirtualCall,
120clang-analyzer-cplusplus.SelfAssignment,
121clang-analyzer-cplusplus.SmartPtrModeling,
122clang-analyzer-cplusplus.VirtualCallModeling,
123clang-analyzer-deadcode.DeadStores,
124clang-analyzer-fuchsia.HandleChecker,
125clang-analyzer-nullability.NullPassedToNonnull,
126clang-analyzer-nullability.NullReturnedFromNonnull,
127clang-analyzer-nullability.NullabilityBase,
128clang-analyzer-nullability.NullableDereferenced,
129clang-analyzer-nullability.NullablePassedToNonnull,
130clang-analyzer-nullability.NullableReturnedFromNonnull,
131clang-analyzer-optin.cplusplus.UninitializedObject,
132clang-analyzer-optin.cplusplus.VirtualCall,
133clang-analyzer-optin.mpi.MPI-Checker,
134clang-analyzer-optin.osx.OSObjectCStyleCast,
135clang-analyzer-optin.osx.cocoa.localizability.EmptyLocalizationContextChecker,
136clang-analyzer-optin.osx.cocoa.localizability.NonLocalizedStringChecker,
137clang-analyzer-optin.performance.GCDAntipattern,
138clang-analyzer-optin.performance.Padding,
139clang-analyzer-optin.portability.UnixAPI,
140clang-analyzer-osx.API,
141clang-analyzer-osx.MIG,
142clang-analyzer-osx.NSOrCFErrorDerefChecker,
143clang-analyzer-osx.NumberObjectConversion,
144clang-analyzer-osx.OSObjectRetainCount,
145clang-analyzer-osx.ObjCProperty,
146clang-analyzer-osx.SecKeychainAPI,
147clang-analyzer-osx.cocoa.AtSync,
148clang-analyzer-osx.cocoa.AutoreleaseWrite,
149clang-analyzer-osx.cocoa.ClassRelease,
150clang-analyzer-osx.cocoa.Dealloc,
151clang-analyzer-osx.cocoa.IncompatibleMethodTypes,
152clang-analyzer-osx.cocoa.Loops,
153clang-analyzer-osx.cocoa.MissingSuperCall,
154clang-analyzer-osx.cocoa.NSAutoreleasePool,
155clang-analyzer-osx.cocoa.NSError,
156clang-analyzer-osx.cocoa.NilArg,
157clang-analyzer-osx.cocoa.NonNilReturnValue,
158clang-analyzer-osx.cocoa.ObjCGenerics,
159clang-analyzer-osx.cocoa.RetainCount,
160clang-analyzer-osx.cocoa.RetainCountBase,
161clang-analyzer-osx.cocoa.RunLoopAutoreleaseLeak,
162clang-analyzer-osx.cocoa.SelfInit,
163clang-analyzer-osx.cocoa.SuperDealloc,
164clang-analyzer-osx.cocoa.UnusedIvars,
165clang-analyzer-osx.cocoa.VariadicMethodTypes,
166clang-analyzer-osx.coreFoundation.CFError,
167clang-analyzer-osx.coreFoundation.CFNumber,
168clang-analyzer-osx.coreFoundation.CFRetainRelease,
169clang-analyzer-osx.coreFoundation.containers.OutOfBounds,
170clang-analyzer-osx.coreFoundation.containers.PointerSizedValues,
171clang-analyzer-security.FloatLoopCounter,
172clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling,
173clang-analyzer-security.insecureAPI.SecuritySyntaxChecker,
174clang-analyzer-security.insecureAPI.UncheckedReturn,
175clang-analyzer-security.insecureAPI.bcmp,
176clang-analyzer-security.insecureAPI.bcopy,
177clang-analyzer-security.insecureAPI.bzero,
178clang-analyzer-security.insecureAPI.decodeValueOfObjCType,
179clang-analyzer-security.insecureAPI.getpw,
180clang-analyzer-security.insecureAPI.gets,
181clang-analyzer-security.insecureAPI.mkstemp,
182clang-analyzer-security.insecureAPI.mktemp,
183clang-analyzer-security.insecureAPI.rand,
184clang-analyzer-security.insecureAPI.strcpy,
185clang-analyzer-security.insecureAPI.vfork,
186clang-analyzer-unix.API,
187clang-analyzer-unix.DynamicMemoryModeling,
188clang-analyzer-unix.Malloc,
189clang-analyzer-unix.MallocSizeof,
190clang-analyzer-unix.MismatchedDeallocator,
191clang-analyzer-unix.Vfork,
192clang-analyzer-unix.cstring.BadSizeArg,
193clang-analyzer-unix.cstring.CStringModeling,
194clang-analyzer-unix.cstring.NullArg,
195clang-analyzer-valist.CopyToSelf,
196clang-analyzer-valist.Uninitialized,
197clang-analyzer-valist.Unterminated,
198clang-analyzer-valist.ValistBase,
199clang-analyzer-webkit.NoUncountedMemberChecker,
200clang-analyzer-webkit.RefCntblBaseVirtualDtor,
201cppcoreguidelines-avoid-c-arrays,
202cppcoreguidelines-avoid-goto,
203cppcoreguidelines-c-copy-assignment-signature,
204cppcoreguidelines-explicit-virtual-functions,
205cppcoreguidelines-init-variables,
206cppcoreguidelines-interfaces-global-init,
207cppcoreguidelines-macro-usage,
208cppcoreguidelines-no-malloc,
209cppcoreguidelines-prefer-member-initializer,
210cppcoreguidelines-pro-bounds-array-to-pointer-decay,
211cppcoreguidelines-pro-type-const-cast,
212cppcoreguidelines-pro-type-cstyle-cast,
213cppcoreguidelines-pro-type-member-init,
214cppcoreguidelines-pro-type-reinterpret-cast,
215cppcoreguidelines-pro-type-static-cast-downcast,
216cppcoreguidelines-pro-type-union-access,
217cppcoreguidelines-pro-type-vararg,
218cppcoreguidelines-slicing,
219google-explicit-constructor,
220misc-misplaced-const,
221misc-redundant-expression,
222misc-static-assert,
223misc-throw-by-value-catch-by-reference,
224misc-unconventional-assign-operator,
225misc-uniqueptr-reset-release,
226misc-unused-using-decls,
227modernize-avoid-bind,
228modernize-deprecated-headers,
229modernize-deprecated-ios-base-aliases,
230modernize-loop-convert,
231modernize-make-shared,
232modernize-make-unique,
233modernize-raw-string-literal,
234modernize-redundant-void-arg,
235modernize-replace-auto-ptr,
236modernize-replace-random-shuffle,
237modernize-return-braced-init-list,
238modernize-shrink-to-fit,
239modernize-unary-static-assert,
240modernize-use-bool-literals,
241modernize-use-default-member-init,
242modernize-use-emplace,
243modernize-use-equals-default,
244modernize-use-equals-delete,
245modernize-use-noexcept,
246modernize-use-nullptr,
247modernize-use-override,
248modernize-use-transparent-functors,
249modernize-use-uncaught-exceptions,
250modernize-use-using,
251performance-faster-string-find,
252performance-for-range-copy,
253performance-implicit-conversion-in-loop,
254performance-inefficient-algorithm,
255performance-inefficient-string-concatenation,
256performance-inefficient-vector-operation,
257performance-move-const-arg,
258performance-move-constructor-init,
259performance-no-automatic-move,
260performance-no-int-to-ptr,
261performance-noexcept-move-constructor,
262performance-trivially-destructible,
263performance-type-promotion-in-math-fn,
264performance-unnecessary-copy-initialization,
265performance-unnecessary-value-param,
266readability-avoid-const-params-in-decls,
267readability-braces-around-statements,
268readability-const-return-type,
269readability-container-size-empty,
270readability-convert-member-functions-to-static,
271readability-delete-null-pointer,
272readability-deleted-default,
273readability-else-after-return,
274readability-function-size,
275readability-identifier-naming,
276readability-implicit-bool-conversion,
277readability-inconsistent-declaration-parameter-name,
278readability-isolate-declaration,
279readability-make-member-function-const,
280readability-misleading-indentation,
281readability-misplaced-array-index,
282readability-named-parameter,
283readability-non-const-parameter,
284readability-qualified-auto,
285readability-redundant-access-specifiers,
286readability-redundant-control-flow,
287readability-redundant-declaration,
288readability-redundant-function-ptr-dereference,
289readability-redundant-member-init,
290readability-redundant-preprocessor,
291readability-redundant-smartptr-get,
292readability-redundant-string-cstr,
293readability-redundant-string-init,
294readability-simplify-boolean-expr,
295readability-simplify-subscript-expr,
296readability-static-accessed-through-instance,
297readability-static-definition-in-anonymous-namespace,
298readability-string-compare,
299readability-suspicious-call-argument,
300readability-uniqueptr-delete-release,
301readability-uppercase-literal-suffix'
302
303WarningsAsErrors: '*'
304HeaderFilterRegex: '(?!^subprojects).*'
305CheckOptions:
306  - { key: readability-identifier-naming.ClassCase,     value: CamelCase  }
307  - { key: readability-identifier-naming.VariableCase,  value: camelBack }
308  - { key: readability-identifier-naming.FunctionCase,  value: camelBack }
309  - { key: readability-identifier-naming.ParameterCase, value: camelBack }
310  - { key: readability-identifier-naming.NamespaceCase, value: lower_case }
311  - { key: readability-identifier-naming.StructCase,    value: CamelCase  }
312