mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
7200776: Implement default methods in interfaces
Add generic type analysis and default method selection algorithms Reviewed-by: coleenp, acorn
This commit is contained in:
parent
ff6a68b801
commit
6563cda42b
27 changed files with 4301 additions and 203 deletions
|
@ -472,6 +472,12 @@ bool Reflection::verify_class_access(Klass* current_class, Klass* new_class, boo
|
|||
return true;
|
||||
}
|
||||
|
||||
// Also allow all accesses from
|
||||
// java/lang/invoke/MagicLambdaImpl subclasses to succeed trivially.
|
||||
if (current_class->is_subclass_of(SystemDictionary::lambda_MagicLambdaImpl_klass())) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return can_relax_access_check_for(current_class, new_class, classloader_only);
|
||||
}
|
||||
|
||||
|
@ -564,6 +570,12 @@ bool Reflection::verify_field_access(Klass* current_class,
|
|||
return true;
|
||||
}
|
||||
|
||||
// Also allow all accesses from
|
||||
// java/lang/invoke/MagicLambdaImpl subclasses to succeed trivially.
|
||||
if (current_class->is_subclass_of(SystemDictionary::lambda_MagicLambdaImpl_klass())) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return can_relax_access_check_for(
|
||||
current_class, field_class, classloader_only);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue