src/hotspot/share/runtime/fieldType.hpp
changeset 58722 cba8afa5cfed
parent 53244 9807daeb47c4
--- a/src/hotspot/share/runtime/fieldType.hpp	Mon Oct 21 09:26:14 2019 -0700
+++ b/src/hotspot/share/runtime/fieldType.hpp	Mon Oct 21 13:13:16 2019 -0400
@@ -58,14 +58,16 @@
   static BasicType basic_type(Symbol* signature);
 
   // Testing
-  static bool is_array(Symbol* signature) { return signature->utf8_length() > 1 && signature->char_at(0) == '[' && is_valid_array_signature(signature); }
+  static bool is_array(Symbol* signature) { return signature->utf8_length() > 1 &&
+                                                   signature->char_at(0) == JVM_SIGNATURE_ARRAY &&
+                                                   is_valid_array_signature(signature); }
 
   static bool is_obj(Symbol* signature) {
      int sig_length = signature->utf8_length();
      // Must start with 'L' and end with ';'
      return (sig_length >= 2 &&
-             (signature->char_at(0) == 'L') &&
-             (signature->char_at(sig_length - 1) == ';'));
+             (signature->char_at(0) == JVM_SIGNATURE_CLASS) &&
+             (signature->char_at(sig_length - 1) == JVM_SIGNATURE_ENDCLASS));
   }
 
   // Parse field and extract array information. Works for T_ARRAY only.