Fix performance-no-automatic-move clang-tidy issues
Test: m tidy-art
Bug: 264654008
Change-Id: I9f8c359c0e5455869b459ae29520fb407b64eaee
diff --git a/build/Android.bp b/build/Android.bp
index 382b0a3..504ed5b 100644
--- a/build/Android.bp
+++ b/build/Android.bp
@@ -42,6 +42,7 @@
"performance-faster-string-find",
"performance-for-range-copy",
"performance-implicit-conversion-in-loop",
+ "performance-no-automatic-move",
"performance-noexcept-move-constructor",
"performance-unnecessary-copy-initialization",
"performance-unnecessary-value-param",
diff --git a/runtime/subtype_check.h b/runtime/subtype_check.h
index 45ca84b..90b9b57 100644
--- a/runtime/subtype_check.h
+++ b/runtime/subtype_check.h
@@ -571,9 +571,7 @@
DCHECK_EQ(depth, klass->Depth());
SubtypeCheckBitsAndStatus current_bits_and_status = ReadField(klass);
- const SubtypeCheckInfo current =
- SubtypeCheckInfo::Create(current_bits_and_status.subtype_check_info_, depth);
- return current;
+ return SubtypeCheckInfo::Create(current_bits_and_status.subtype_check_info_, depth);
}
static void SetSubtypeCheckInfo(ClassPtr klass, const SubtypeCheckInfo& new_sci)