src/share/vm/utilities/constantTag.hpp

changeset 1957
136b78722a08
parent 1907
c18cbe5936b8
child 2015
083fde3b838e
     1.1 --- a/src/share/vm/utilities/constantTag.hpp	Mon Jun 07 14:17:01 2010 -0700
     1.2 +++ b/src/share/vm/utilities/constantTag.hpp	Wed Jun 09 18:50:45 2010 -0700
     1.3 @@ -78,13 +78,24 @@
     1.4    bool is_field_or_method() const   { return is_field() || is_method() || is_interface_method(); }
     1.5    bool is_symbol() const            { return is_utf8(); }
     1.6  
     1.7 +  bool is_method_type() const              { return _tag == JVM_CONSTANT_MethodType; }
     1.8 +  bool is_method_handle() const            { return _tag == JVM_CONSTANT_MethodHandle; }
     1.9 +
    1.10 +  constantTag() {
    1.11 +    _tag = JVM_CONSTANT_Invalid;
    1.12 +  }
    1.13    constantTag(jbyte tag) {
    1.14      assert((tag >= 0 && tag <= JVM_CONSTANT_NameAndType) ||
    1.15 +           (tag >= JVM_CONSTANT_MethodHandle && tag <= JVM_CONSTANT_MethodType) ||
    1.16             (tag >= JVM_CONSTANT_InternalMin && tag <= JVM_CONSTANT_InternalMax), "Invalid constant tag");
    1.17      _tag = tag;
    1.18    }
    1.19  
    1.20    jbyte value()                      { return _tag; }
    1.21  
    1.22 +  BasicType basic_type() const;        // if used with ldc, what kind of value gets pushed?
    1.23 +
    1.24 +  const char* internal_name() const;  // for error reporting
    1.25 +
    1.26    void print_on(outputStream* st) const PRODUCT_RETURN;
    1.27  };

mercurial