mirror of
https://github.com/i-net-software/JWebAssembly.git
synced 2025-03-15 02:44:47 +01:00
Make interfaces castable to java/lang/Object
This commit is contained in:
parent
a936504c4c
commit
de1befcc1d
@ -654,6 +654,9 @@ public class TypeManager {
|
||||
|
||||
// interface does not need to resolve
|
||||
if( classFile.getType() == Type.Interface ) {
|
||||
// to make it possible to cast an interface to java/lang/Object it must have the same fileds also if we never create an instance
|
||||
fields.add( new NamedStorageType( ValueType.i32, className, FIELD_VTABLE ) );
|
||||
fields.add( new NamedStorageType( ValueType.i32, className, FIELD_HASHCODE ) );
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user