diff options
author | Stephen Hines <srhines@google.com> | 2020-06-09 00:13:57 -0700 |
---|---|---|
committer | Stephen Hines <srhines@google.com> | 2020-06-09 00:15:27 -0700 |
commit | ab17065423a7b6fe9416885258eb0a6bdb1a79a9 (patch) | |
tree | 6a25a4cacf82c0ae5472ef7e34036c9db3cc5357 | |
parent | 8cf0793c433c8609cb3cf4c13f5b59103f456f77 (diff) |
Use `tidy_checks_as_errors` list instead of `-warnings-as-errors=*`
This fixes a build break due to new code from
http://ag/I96f970e82b5243be01b205ac2cb6ab249c6100bc that inadvertently
triggers some false positives with other clang-tidy flags. Builds that
use a wider set of tidy flags (as specified in the test below) will
break since `-warnings-as-errors=*` turns all warnings into errors,
rather than just the ones that were specified as part of this
Android.bp. The preferred way of checking this is to use
`tidy_checks_as_errors`
Bug: 119328308
Test: WITH_TIDY=1 DEFAULT_GLOBAL_TIDY_CHECKS=*,-readability-*,-google-readability-*,-google-runtime-references,-cppcoreguidelines-*,-modernize-*,-llvm-*,-bugprone-narrowing-conversions,-misc-non-private-member-variables-in-classes,-misc-unused-parameters,-hicpp-*,-fuchsia-* mm
Change-Id: I941b3c89402e2cfa290b3829e2ac8ff7ea67ca3d
Merged-In: I941b3c89402e2cfa290b3829e2ac8ff7ea67ca3d
(cherry picked from commit 0bc64543270b16e1953b399dc73fa739132a6e5f)
-rw-r--r-- | cmds/idmap2/Android.bp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/cmds/idmap2/Android.bp b/cmds/idmap2/Android.bp index ce56baecab71..771c0ef5260a 100644 --- a/cmds/idmap2/Android.bp +++ b/cmds/idmap2/Android.bp @@ -15,7 +15,7 @@ cc_defaults { name: "idmap2_defaults", tidy: true, - tidy_checks: [ + tidy_checks_as_errors: [ "modernize-*", "-modernize-avoid-c-arrays", "-modernize-use-trailing-return-type", @@ -25,7 +25,6 @@ cc_defaults { ], tidy_flags: [ "-system-headers", - "-warnings-as-errors=*,-bugprone*", ], } |