7056328: JSR 292 invocation sometimes fails in adapters for types not on boot class path

Reviewed-by: never
This commit is contained in:
John R Rose 2011-06-23 17:14:06 -07:00
parent 15161b8cd1
commit 8df44305c7
26 changed files with 512 additions and 58 deletions

View file

@ -2574,6 +2574,18 @@ Symbol* java_lang_invoke_MethodType::as_signature(oop mt, bool intern_if_not_fou
return name;
}
bool java_lang_invoke_MethodType::equals(oop mt1, oop mt2) {
if (rtype(mt1) != rtype(mt2))
return false;
if (ptype_count(mt1) != ptype_count(mt2))
return false;
for (int i = ptype_count(mt1) - 1; i >= 0; i--) {
if (ptype(mt1, i) != ptype(mt2, i))
return false;
}
return true;
}
oop java_lang_invoke_MethodType::rtype(oop mt) {
assert(is_instance(mt), "must be a MethodType");
return mt->obj_field(_rtype_offset);