Add -Xcheck:jni.
I think this is as complete as possible right now. The remaining
two #if 0 sections require:
1. a way to get the Method* of the current native method.
2. a way to get the Class* of the type of a given Field*.
Change-Id: I331586022095fb36ccc10c9ac1890a59a9224d01
diff --git a/src/utils.h b/src/utils.h
index 6bc27a8..4b3e57e 100644
--- a/src/utils.h
+++ b/src/utils.h
@@ -10,6 +10,7 @@
namespace art {
+class Field;
class Method;
class Object;
class String;
@@ -142,6 +143,9 @@
// "java.lang.String[]", and so forth.
std::string PrettyDescriptor(const String* descriptor);
+// Returns a human-readable signature for 'f'. Something like "a.b.C.f".
+std::string PrettyField(const Field* f);
+
// Returns a human-readable signature for 'm'. Something like "a.b.C.m" or
// "a.b.C.m(II)V" (depending on the value of 'with_signature').
std::string PrettyMethod(const Method* m, bool with_signature = true);