use of st.gravel.support.compiler.ast.MethodMapping in project gravel by gravel-st.
the class LiteralBlockSendCallSite method findMethod.
@Override
protected MethodHandle findMethod(Class receiverClass) {
MethodMapping methodMapping = ImageBootstrapper.systemMapping.methodMappingFor_methodName_(receiverClass, selector);
if (methodMapping == null) {
return createDNUHandle(receiverClass).asType(type);
}
MethodNode methodNode = methodMapping.methodNode();
return inlineBlocks(methodNode, ImageBootstrapper.systemMapping.classMappingForJavaClass_(receiverClass).reference(), (JVMNonPrimitiveType) ImageBootstrapper.systemMapping.compilerTools().jvmTypeForClass_(receiverClass));
}
use of st.gravel.support.compiler.ast.MethodMapping in project gravel by gravel-st.
the class LiteralBlockSendCallSite method findMethodForNil.
@Override
protected MethodHandle findMethodForNil() {
MethodMapping methodMapping = ImageBootstrapper.systemMapping.methodMappingForNil_(selector);
if (methodMapping == null) {
return createDNUHandleForNil();
}
MethodNode methodNode = methodMapping.methodNode();
return inlineBlocks(methodNode, ImageBootstrapper.systemMapping.nilClassMapping().reference(), JVMDefinedObjectType.factory.object());
}
Aggregations