diff options
author | 2022-01-12 21:14:17 -0800 | |
---|---|---|
committer | 2022-01-14 20:04:41 +0000 | |
commit | c5f41cd1a39472dbe2480c09a1ce20aeced2a9f6 (patch) | |
tree | 6a8a0aa66c68e8a4c49833b2a93b263985259aed | |
parent | 37af46385e24afddee1b609d9e30750ae06cb84d (diff) |
Allow some clang-tidy warnings
* Allow them before all those warnings are fixed in source files.
Bug: 213953102
Test: unset WITH_TIDY; make tidy-art
Change-Id: I5dbfed236bdb2d706b78729e5c6ac192b78e4ad5
-rw-r--r-- | build/Android.bp | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/build/Android.bp b/build/Android.bp index 657aa12ca0..d2545a401d 100644 --- a/build/Android.bp +++ b/build/Android.bp @@ -28,23 +28,28 @@ bootstrap_go_package { } art_clang_tidy_errors = [ - "android-cloexec-dup", "android-cloexec-open", - "bugprone-argument-comment", "bugprone-lambda-function-name", "bugprone-unused-raii", // Protect scoped things like MutexLock. - "bugprone-unused-return-value", "bugprone-virtual-near-miss", "modernize-use-bool-literals", + "performance-implicit-conversion-in-loop", + "performance-unnecessary-copy-initialization", +] + +art_clang_tidy_allowed = [ + // Many files have these warnings. Move them to art_clang_tidy_errors + // when all files are free of these warnings. + "android-cloexec-dup", + "bugprone-argument-comment", + "bugprone-unused-return-value", + "misc-unused-using-decls", "modernize-use-nullptr", "modernize-use-using", "performance-faster-string-find", "performance-for-range-copy", - "performance-implicit-conversion-in-loop", "performance-noexcept-move-constructor", - "performance-unnecessary-copy-initialization", "performance-unnecessary-value-param", - "misc-unused-using-decls", ] art_clang_tidy_disabled = [ @@ -241,7 +246,8 @@ art_module_art_global_defaults { }, }, - tidy_checks: art_clang_tidy_errors + art_clang_tidy_disabled, + tidy_checks: art_clang_tidy_errors + art_clang_tidy_allowed + art_clang_tidy_disabled, + tidy_checks_as_errors: art_clang_tidy_errors, tidy_flags: [ @@ -348,6 +354,7 @@ java_library { // from sources. TODO(b/172480617): Clean up when sources are gone from the // platform tree and we no longer need to support sources present when prebuilts // are used. + art_module_cc_defaults { name: "art_module_source_build_defaults", defaults_visibility: [ @@ -369,6 +376,7 @@ art_module_cc_defaults { }, }, } + art_module_java_defaults { name: "art_module_source_build_java_defaults", defaults_visibility: [ @@ -388,6 +396,7 @@ art_module_java_defaults { }, }, } + art_module_genrule_defaults { name: "art_module_source_build_genrule_defaults", defaults_visibility: [ @@ -407,6 +416,7 @@ art_module_genrule_defaults { }, }, } + art_module_prebuilt_defaults { name: "art_module_source_build_prebuilt_defaults", defaults_visibility: [ |