Skip compilation of dead code from duplicate methods
Change-Id: If6114b3cd8e9a2d9a901dc93c352cee6afa3361f
diff --git a/src/utils.cc b/src/utils.cc
index 629d513..4e35cd2 100644
--- a/src/utils.cc
+++ b/src/utils.cc
@@ -257,6 +257,19 @@
return result;
}
+std::string PrettyField(uint32_t field_idx, const DexFile& dex_file, bool with_type) {
+ const DexFile::FieldId& field_id = dex_file.GetFieldId(field_idx);
+ std::string result;
+ if (with_type) {
+ result += dex_file.GetFieldTypeDescriptor(field_id);
+ result += ' ';
+ }
+ result += PrettyDescriptor(dex_file.GetFieldDeclaringClassDescriptor(field_id));
+ result += '.';
+ result += dex_file.GetFieldName(field_id);
+ return result;
+}
+
std::string PrettyArguments(const char* signature) {
std::string result;
result += '(';