summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Andreas Gampe <agampe@google.com> 2018-09-18 13:50:29 -0700
committer Andreas Gampe <agampe@google.com> 2018-09-18 16:02:05 -0700
commit322c0891ebc1cf3e3b28d4cbb003b0e40506bc32 (patch)
tree0259f437c2b2ad2e82b46989930495d0bdc99008
parent157f9401baf3c0dcf4509c53e556556d9158ba1d (diff)
ART: Add tidy errors
Add some of the recently fixed categories as errors. Also add some suppressed categories. Bug: 32619234 Test: WITH_TIDY=1 mmma art Change-Id: Ifd33b2414c28094d152b2626ee8fd1a46c377f38
-rw-r--r--build/Android.bp20
1 files changed, 17 insertions, 3 deletions
diff --git a/build/Android.bp b/build/Android.bp
index 62f71ff275..85577984d6 100644
--- a/build/Android.bp
+++ b/build/Android.bp
@@ -18,16 +18,25 @@ bootstrap_go_package {
}
art_clang_tidy_errors = [
- // Protect scoped things like MutexLock.
- "bugprone-unused-raii",
+ "bugprone-lambda-function-name",
+ "bugprone-unused-raii", // Protect scoped things like MutexLock.
+ "bugprone-virtual-near-miss",
+ "modernize-use-nullptr",
+ "performance-faster-string-find",
"performance-for-range-copy",
+ "performance-implicit-conversion-in-loop",
"performance-unnecessary-copy-initialization",
"performance-unnecessary-value-param",
"misc-unused-using-decls",
]
// Should be: strings.Join(art_clang_tidy_errors, ",").
-art_clang_tidy_errors_str = "bugprone-unused-raii"
+art_clang_tidy_errors_str = "bugprone-lambda-function-name"
+ + ",bugprone-unused-raii"
+ + ",bugprone-virtual-near-miss"
+ + ",modernize-use-nullptr"
+ + ",performance-faster-string-find"
+ ",performance-for-range-copy"
+ + ",performance-implicit-conversion-in-loop"
+ ",performance-unnecessary-copy-initialization"
+ ",performance-unnecessary-value-param"
+ ",misc-unused-using-decls"
@@ -44,6 +53,11 @@ art_clang_tidy_disabled = [
// No exceptions.
"-misc-noexcept-move-constructor",
"-performance-noexcept-move-constructor",
+ // "Modernization" we don't agree with.
+ "-modernize-use-auto",
+ "-modernize-return-braced-init-list",
+ "-modernize-use-default-member-init",
+ "-modernize-pass-by-value",
]
art_global_defaults {