forked from openkylin/platform_build
Recognize more clang-tidy compiler warnings.
* Some are from clang compiler and Android makefile checker. Test: run with build.log Change-Id: I371f08f3ae956e9425515b2cd67c5af3d0425b89
This commit is contained in:
parent
89b40fa645
commit
9e9355dac6
|
@ -177,6 +177,9 @@ warn_patterns = [
|
|||
{'category': 'make', 'severity': Severity.MEDIUM,
|
||||
'description': 'Invalid SDK/NDK linking',
|
||||
'patterns': [r".*: warning: .+ \(.+\) should not link to .+ \(.+\)"]},
|
||||
{'category': 'make', 'severity': Severity.MEDIUM,
|
||||
'description': 'Duplicate header copy',
|
||||
'patterns': [r".*: warning: Duplicate header copy: .+"]},
|
||||
{'category': 'C/C++', 'severity': Severity.HIGH, 'option': '-Wimplicit-function-declaration',
|
||||
'description': 'Implicit function declaration',
|
||||
'patterns': [r".*: warning: implicit declaration of function .+",
|
||||
|
@ -238,9 +241,11 @@ warn_patterns = [
|
|||
'description': 'Unused parameter',
|
||||
'patterns': [r".*: warning: unused parameter '.*'"]},
|
||||
{'category': 'C/C++', 'severity': Severity.MEDIUM, 'option': '-Wunused',
|
||||
'description': 'Unused function, variable or label',
|
||||
'description': 'Unused function, variable, label, comparison, etc.',
|
||||
'patterns': [r".*: warning: '.+' defined but not used",
|
||||
r".*: warning: unused function '.+'",
|
||||
r".*: warning: unused label '.+'",
|
||||
r".*: warning: relational comparison result unused",
|
||||
r".*: warning: lambda capture .* is not used",
|
||||
r".*: warning: private field '.+' is not used",
|
||||
r".*: warning: unused variable '.+'"]},
|
||||
|
@ -2513,6 +2518,29 @@ warn_patterns = [
|
|||
|
||||
# warnings from clang-tidy
|
||||
group_tidy_warn_pattern('android'),
|
||||
simple_tidy_warn_pattern('bugprone-argument-comment'),
|
||||
simple_tidy_warn_pattern('bugprone-copy-constructor-init'),
|
||||
simple_tidy_warn_pattern('bugprone-fold-init-type'),
|
||||
simple_tidy_warn_pattern('bugprone-forward-declaration-namespace'),
|
||||
simple_tidy_warn_pattern('bugprone-forwarding-reference-overload'),
|
||||
simple_tidy_warn_pattern('bugprone-inaccurate-erase'),
|
||||
simple_tidy_warn_pattern('bugprone-incorrect-roundings'),
|
||||
simple_tidy_warn_pattern('bugprone-integer-division'),
|
||||
simple_tidy_warn_pattern('bugprone-lambda-function-name'),
|
||||
simple_tidy_warn_pattern('bugprone-macro-parentheses'),
|
||||
simple_tidy_warn_pattern('bugprone-misplaced-widening-cast'),
|
||||
simple_tidy_warn_pattern('bugprone-move-forwarding-reference'),
|
||||
simple_tidy_warn_pattern('bugprone-sizeof-expression'),
|
||||
simple_tidy_warn_pattern('bugprone-string-constructor'),
|
||||
simple_tidy_warn_pattern('bugprone-string-integer-assignment'),
|
||||
simple_tidy_warn_pattern('bugprone-suspicious-enum-usage'),
|
||||
simple_tidy_warn_pattern('bugprone-suspicious-missing-comma'),
|
||||
simple_tidy_warn_pattern('bugprone-suspicious-string-compare'),
|
||||
simple_tidy_warn_pattern('bugprone-suspicious-semicolon'),
|
||||
simple_tidy_warn_pattern('bugprone-undefined-memory-manipulation'),
|
||||
simple_tidy_warn_pattern('bugprone-unused-raii'),
|
||||
simple_tidy_warn_pattern('bugprone-use-after-move'),
|
||||
group_tidy_warn_pattern('bugprone'),
|
||||
group_tidy_warn_pattern('cert'),
|
||||
group_tidy_warn_pattern('clang-diagnostic'),
|
||||
group_tidy_warn_pattern('cppcoreguidelines'),
|
||||
|
|
Loading…
Reference in New Issue