mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8270404: Better canonicalization
Reviewed-by: coleenp, rhalade, mschoene
This commit is contained in:
parent
24b588eddb
commit
76373ae3c8
2 changed files with 19 additions and 0 deletions
|
@ -3066,6 +3066,18 @@ InstanceKlass* InstanceKlass::compute_enclosing_class(bool* inner_is_member, TRA
|
|||
constantPoolHandle i_cp(THREAD, constants());
|
||||
if (ooff != 0) {
|
||||
Klass* ok = i_cp->klass_at(ooff, CHECK_NULL);
|
||||
if (!ok->is_instance_klass()) {
|
||||
// If the outer class is not an instance klass then it cannot have
|
||||
// declared any inner classes.
|
||||
ResourceMark rm(THREAD);
|
||||
Exceptions::fthrow(
|
||||
THREAD_AND_LOCATION,
|
||||
vmSymbols::java_lang_IncompatibleClassChangeError(),
|
||||
"%s and %s disagree on InnerClasses attribute",
|
||||
ok->external_name(),
|
||||
external_name());
|
||||
return NULL;
|
||||
}
|
||||
outer_klass = InstanceKlass::cast(ok);
|
||||
*inner_is_member = true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue