1- # SPDX-FileCopyrightText: 2019-2024 SeisSol Group
1+ # SPDX-FileCopyrightText: 2022 SeisSol Group
22#
33# SPDX-License-Identifier: BSD-3-Clause
4+ # SPDX-LicenseComments: Full text under /LICENSE and /LICENSES/
5+ #
6+ # SPDX-FileContributor: Author lists in /AUTHORS and /CITATION.cff
7+
8+ # TODO: apply
9+ # * modernize-use-trailing-return-type
10+ # * readability-function-size
11+ # * cppcoreguidelines-pro-type-const-cast
12+ # * readability-convert-member-functions-to-static
13+ # * clang-analyzer-cplusplus.NewDeleteLeaks
14+ # * clang-analyzer-optin.cplusplus.VirtualCall
15+ # * clang-analyzer-deadcode.DeadStores
16+ # * bugprone-narrowing-conversions,
17+ # * bugprone-easily-swappable-parameters,
18+ # * bugprone-unchecked-optional-access,
19+ # * bugprone-crtp-constructor-accessibility,
20+ # * bugprone-branch-clone,
21+ # * cppcoreguidelines-use-enum-class
22+ # * google-runtime-int
423
5- Checks : ' -*,clang-diagnostic-*,llvm-*,misc-*,-misc-unused-parameters,-llvm-header-guard,-misc-non-private-member-variables-in-classes,readability-identifier-naming'
6- # WarningsAsErrors: 'readability-identifier-naming'
24+ Checks :
25+ - google-*
26+ - -google-readability-todo
27+ - -google-runtime-int
28+ - -google-build-using-namespace
29+ - -google-default-arguments
30+ - cert-*
31+ - -cert-err58-cpp
32+ - openmp-*
33+ - -openmp-use-default-none
34+ - concurrency-*
35+ - -clang-analyzer-cplusplus.NewDeleteLeaks
36+ - -clang-analyzer-optin.cplusplus.VirtualCall
37+ - -clang-analyzer-deadcode.DeadStores
38+ - bugprone-*
39+ - -bugprone-narrowing-conversions
40+ - -bugprone-easily-swappable-parameters
41+ - -bugprone-unchecked-optional-access
42+ - -bugprone-crtp-constructor-accessibility
43+ - -bugprone-branch-clone
44+ - clang-diagnostic-*
45+ - cppcoreguidelines-*
46+ - -cppcoreguidelines-avoid-c-arrays
47+ - -cppcoreguidelines-avoid-const-or-ref-data-members
48+ - -cppcoreguidelines-avoid-magic-numbers
49+ - -cppcoreguidelines-avoid-do-while
50+ - -cppcoreguidelines-macro-usage
51+ - -cppcoreguidelines-no-malloc
52+ - -cppcoreguidelines-non-private-member-variables-in-classes
53+ - -cppcoreguidelines-pro-bounds-array-to-pointer-decay
54+ - -cppcoreguidelines-pro-bounds-constant-array-index
55+ - -cppcoreguidelines-owning-memory
56+ - -cppcoreguidelines-pro-bounds-pointer-arithmetic
57+ - -cppcoreguidelines-pro-type-reinterpret-cast
58+ - -cppcoreguidelines-narrowing-conversions
59+ - -cppcoreguidelines-pro-type-const-cast
60+ - -cppcoreguidelines-use-enum-class
61+ - llvm-*
62+ - -llvm-else-after-return
63+ - -llvm-header-guard
64+ - -llvm-qualified-auto
65+ - -llvm-prefer-static-over-anonymous-namespace
66+ - misc-*
67+ - -misc-non-private-member-variables-in-classes
68+ - -misc-no-recursion
69+ - modernize-*
70+ - -modernize-avoid-c-arrays
71+ - -modernize-deprecated-headers
72+ - -modernize-loop-convert
73+ - -modernize-pass-by-value
74+ - -modernize-return-braced-init-list
75+ - -modernize-use-trailing-return-type
76+ - mpi-*
77+ - performance-*
78+ - -performance-enum-size
79+ - -performance-avoid-endl
80+ - readability-*
81+ - -readability-else-after-return
82+ - -readability-identifier-length
83+ - -readability-magic-numbers
84+ - -readability-math-missing-parentheses
85+ - -readability-function-cognitive-complexity
86+ - -readability-function-size
87+ - -readability-suspicious-call-argument
88+ - -readability-convert-member-functions-to-static
89+ WarningsAsErrors : ' *'
790CheckOptions :
891# - key: readability-identifier-naming.AbstractClassCase
992# value: CamelCase
@@ -22,7 +105,7 @@ CheckOptions:
22105# - key: readability-identifier-naming.ClassConstantPrefix
23106# value: CamelCase
24107# - key: readability-identifier-naming.ClassConstantSuffix
25- # value: CamelCase-*,clang-diagnostic-*,llvm-*,misc-*,-misc-unused-parameters,-misc-non-private-member-variables-in-classes,
108+ # value: CamelCase
26109# - key: readability-identifier-naming.ClassMemberCase
27110# value: CamelCase
28111# - key: readability-identifier-naming.ClassMemberPrefix
@@ -36,7 +119,7 @@ CheckOptions:
36119# - key: readability-identifier-naming.ClassMethodSuffix
37120# value: CamelCase
38121 - key : readability-identifier-naming.ConstantCase
39- value : UPPER_CASE
122+ value : camelBack
40123# - key: readability-identifier-naming.ConstantPrefix
41124# value: CamelCase
42125# - key: readability-identifier-naming.ConstantSuffix
@@ -71,8 +154,8 @@ CheckOptions:
71154# value: CamelCase
72155# - key: readability-identifier-naming.ConstexprMethodSuffix
73156# value: CamelCase
74- # - key: readability-identifier-naming.ConstexprVariableCase
75- # value: CamelCase
157+ - key : readability-identifier-naming.ConstexprVariableCase
158+ value : CamelCase
76159# - key: readability-identifier-naming.ConstexprVariablePrefix
77160# value: CamelCase
78161# - key: readability-identifier-naming.ConstexprVariableSuffix
@@ -95,8 +178,8 @@ CheckOptions:
95178# value: CamelCase
96179# - key: readability-identifier-naming.FunctionSuffix
97180# value: CamelCase
98- # - key: readability-identifier-naming.GlobalConstantCase
99- # value: CamelCase
181+ - key : readability-identifier-naming.GlobalConstantCase
182+ value : CamelCase
100183# - key: readability-identifier-naming.GlobalConstantPrefix
101184# value: CamelCase
102185# - key: readability-identifier-naming.GlobalConstantSuffix
@@ -159,10 +242,12 @@ CheckOptions:
159242# value: CamelCase
160243 - key : readability-identifier-naming.MemberCase
161244 value : camelBack
162- - key : readability-identifier-naming.MemberPrefix
163- value : " "
245+ - key : readability-identifier-naming.MemberIgnoredRegexp
246+ value : " ^m_|_$" # TODO: temporary! Remove after more refactoring.
247+ # - key: readability-identifier-naming.MemberPrefix
248+ # value: ""
164249# - key: readability-identifier-naming.MemberSuffix
165- # value: CamelCase
250+ # value: ""
166251# - key: readability-identifier-naming.MethodCase
167252# value: CamelCase
168253# - key: readability-identifier-naming.MethodPrefix
@@ -229,8 +314,8 @@ CheckOptions:
229314# value: CamelCase
230315# - key: readability-identifier-naming.PublicMethodSuffix
231316# value: CamelCase
232- # - key: readability-identifier-naming.StaticConstantCase
233- # value: CamelCase
317+ - key : readability-identifier-naming.StaticConstantCase
318+ value : CamelCase
234319# - key: readability-identifier-naming.StaticConstantPrefix
235320# value: CamelCase
236321# - key: readability-identifier-naming.StaticConstantSuffix
@@ -247,26 +332,26 @@ CheckOptions:
247332# value: CamelCase
248333# - key: readability-identifier-naming.StructSuffix
249334# value: CamelCase
250- # - key: readability-identifier-naming.TemplateParameterCase
251- # value: CamelCase
335+ - key : readability-identifier-naming.TemplateParameterCase
336+ value : CamelCase
252337# - key: readability-identifier-naming.TemplateParameterPrefix
253338# value: CamelCase
254339# - key: readability-identifier-naming.TemplateParameterSuffix
255340# value: CamelCase
256- # - key: readability-identifier-naming.TemplateTemplateParameterCase
257- # value: CamelCase
341+ - key : readability-identifier-naming.TemplateTemplateParameterCase
342+ value : CamelCase
258343# - key: readability-identifier-naming.TemplateTemplateParameterPrefix
259344# value: CamelCase
260345# - key: readability-identifier-naming.TemplateTemplateParameterSuffix
261346# value: CamelCase
262- # - key: readability-identifier-naming.TypeAliasCase
263- # value: CamelCase
347+ - key : readability-identifier-naming.TypeAliasCase
348+ value : CamelCase
264349# - key: readability-identifier-naming.TypeAliasPrefix
265350# value: CamelCase
266351# - key: readability-identifier-naming.TypeAliasSuffix
267352# value: CamelCase
268- # - key: readability-identifier-naming.TypedefCase
269- # value: CamelCase
353+ - key : readability-identifier-naming.TypedefCase
354+ value : CamelCase
270355# - key: readability-identifier-naming.TypedefPrefix
271356# value: CamelCase
272357# - key: readability-identifier-naming.TypedefSuffix
@@ -301,3 +386,11 @@ CheckOptions:
301386# value: CamelCase
302387# - key: readability-identifier-naming.VirtualMethodSuffix
303388# value: CamelCase
389+
390+ # ignore Eigen, yaml-cpp, and HDF5 manually, until added to IWYU
391+ # Eigen needs to ignore Eigen/Core and Eigen/Eigenvalues, until we make Eigen3 5.0.0 mandatory
392+ # also, ignore internal GCC headers (bits/)
393+ - key : misc-include-cleaner.IgnoreHeaders
394+ value : ' bits/.*|external/.*'
395+ - key : cppcoreguidelines-special-member-functions.AllowSoleDefaultDtor
396+ value : True
0 commit comments