wasm: fix Array.get with enabled inlining

This commit is contained in:
Alexey Andreev 2023-08-22 17:11:04 +02:00
parent d7cae4af55
commit f6131a8248

View File

@ -109,7 +109,11 @@ public class ArrayGenerator implements WasmMethodGenerator {
MethodReference methodRef = new MethodReference(wrapper, "valueOf", MethodReference methodRef = new MethodReference(wrapper, "valueOf",
primitiveTypes[i], ValueType.object(wrapper)); primitiveTypes[i], ValueType.object(wrapper));
ClassReader cls = context.getClassSource().get(methodRef.getClassName()); ClassReader cls = context.getClassSource().get(methodRef.getClassName());
if (cls == null || cls.getMethod(methodRef.getDescriptor()) == null) { if (cls == null) {
continue;
}
var valueOfMethod = cls.getMethod(methodRef.getDescriptor());
if (valueOfMethod == null || valueOfMethod.getProgram() == null) {
continue; continue;
} }