@Override public DynamicMethod dup() { return new CompiledIRMethod(method, name, file, line, scope, visibility, implementationClass); }
@Override public DynamicMethod dup() { return new CompiledIRMethod(method, name, file, line, scope, visibility, implementationClass); }
@JIT public static DynamicMethod newCompiledModuleBody(ThreadContext context, MethodHandle handle, IRScope irModule, Object rubyContainer) { RubyModule newRubyModule = newRubyModuleFromIR(context, irModule, rubyContainer); return new CompiledIRMethod(handle, irModule, Visibility.PUBLIC, newRubyModule); }
@JIT public static DynamicMethod newCompiledClassBody(ThreadContext context, MethodHandle handle, IRScope irClassBody, Object container, Object superClass) { RubyModule newRubyClass = newRubyClassFromIR(context.runtime, irClassBody, superClass, container); return new CompiledIRMethod(handle, irClassBody, Visibility.PUBLIC, newRubyClass); }
@JIT public static DynamicMethod newCompiledClassBody(ThreadContext context, MethodHandle handle, IRScope irClassBody, Object container, Object superClass) { RubyModule newRubyClass = newRubyClassFromIR(context.runtime, irClassBody, superClass, container); return new CompiledIRMethod(handle, irClassBody, Visibility.PUBLIC, newRubyClass); }
@JIT public static DynamicMethod newCompiledModuleBody(ThreadContext context, MethodHandle handle, IRScope irModule, Object rubyContainer) { RubyModule newRubyModule = newRubyModuleFromIR(context, irModule, rubyContainer); return new CompiledIRMethod(handle, irModule, Visibility.PUBLIC, newRubyModule); }
@JIT public static void defCompiledInstanceMethod(ThreadContext context, MethodHandle handle, IRScope method, DynamicScope currDynScope, IRubyObject self) { Ruby runtime = context.runtime; RubySymbol methodName = method.getName(); RubyModule clazz = findInstanceMethodContainer(context, currDynScope, self); Visibility currVisibility = context.getCurrentVisibility(); Visibility newVisibility = Helpers.performNormalMethodChecksAndDetermineVisibility(runtime, clazz, methodName, currVisibility); DynamicMethod newMethod = new CompiledIRMethod(handle, method, newVisibility, clazz); // FIXME: needs checkID and proper encoding to force hard symbol Helpers.addInstanceMethod(clazz, methodName, newMethod, currVisibility, context, runtime); }
@JIT public static void defCompiledInstanceMethod(ThreadContext context, MethodHandle variable, MethodHandle specific, int specificArity, IRScope method, DynamicScope currDynScope, IRubyObject self) { Ruby runtime = context.runtime; RubySymbol methodName = method.getName(); RubyModule clazz = findInstanceMethodContainer(context, currDynScope, self); Visibility currVisibility = context.getCurrentVisibility(); Visibility newVisibility = Helpers.performNormalMethodChecksAndDetermineVisibility(runtime, clazz, methodName, currVisibility); DynamicMethod newMethod = new CompiledIRMethod(variable, specific, specificArity, method, newVisibility, clazz); // FIXME: needs checkID and proper encoding to force hard symbol Helpers.addInstanceMethod(clazz, methodName, newMethod, currVisibility, context, runtime); }
@JIT public static void defCompiledInstanceMethod(ThreadContext context, MethodHandle handle, IRScope method, DynamicScope currDynScope, IRubyObject self) { Ruby runtime = context.runtime; RubySymbol methodName = method.getName(); RubyModule clazz = findInstanceMethodContainer(context, currDynScope, self); Visibility currVisibility = context.getCurrentVisibility(); Visibility newVisibility = Helpers.performNormalMethodChecksAndDetermineVisibility(runtime, clazz, methodName, currVisibility); DynamicMethod newMethod = new CompiledIRMethod(handle, method, newVisibility, clazz); // FIXME: needs checkID and proper encoding to force hard symbol Helpers.addInstanceMethod(clazz, methodName, newMethod, currVisibility, context, runtime); }
@JIT public static void defCompiledInstanceMethod(ThreadContext context, MethodHandle variable, MethodHandle specific, int specificArity, IRScope method, DynamicScope currDynScope, IRubyObject self) { Ruby runtime = context.runtime; RubySymbol methodName = method.getName(); RubyModule clazz = findInstanceMethodContainer(context, currDynScope, self); Visibility currVisibility = context.getCurrentVisibility(); Visibility newVisibility = Helpers.performNormalMethodChecksAndDetermineVisibility(runtime, clazz, methodName, currVisibility); DynamicMethod newMethod = new CompiledIRMethod(variable, specific, specificArity, method, newVisibility, clazz); // FIXME: needs checkID and proper encoding to force hard symbol Helpers.addInstanceMethod(clazz, methodName, newMethod, currVisibility, context, runtime); }
@JIT public static void defCompiledClassMethod(ThreadContext context, MethodHandle handle, IRScope method, IRubyObject obj) { RubySymbol methodName = method.getName(); RubyClass rubyClass = checkClassForDef(context, method, obj); // FIXME: needs checkID and proper encoding to force hard symbol rubyClass.addMethod(methodName.idString(), new CompiledIRMethod(handle, method, Visibility.PUBLIC, rubyClass)); if (!rubyClass.isRefinement()) { // FIXME: needs checkID and proper encoding to force hard symbol obj.callMethod(context, "singleton_method_added", methodName); } }
@JIT public static void defCompiledClassMethod(ThreadContext context, MethodHandle variable, MethodHandle specific, int specificArity, IRScope method, IRubyObject obj) { RubyClass rubyClass = checkClassForDef(context, method, obj); rubyClass.addMethod(method.getId(), new CompiledIRMethod(variable, specific, specificArity, method, Visibility.PUBLIC, rubyClass)); if (!rubyClass.isRefinement()) obj.callMethod(context, "singleton_method_added", method.getName()); }
@JIT public static void defCompiledClassMethod(ThreadContext context, MethodHandle handle, IRScope method, IRubyObject obj) { RubySymbol methodName = method.getName(); RubyClass rubyClass = checkClassForDef(context, method, obj); // FIXME: needs checkID and proper encoding to force hard symbol rubyClass.addMethod(methodName.idString(), new CompiledIRMethod(handle, method, Visibility.PUBLIC, rubyClass)); if (!rubyClass.isRefinement()) { // FIXME: needs checkID and proper encoding to force hard symbol obj.callMethod(context, "singleton_method_added", methodName); } }
@JIT public static void defCompiledClassMethod(ThreadContext context, MethodHandle variable, MethodHandle specific, int specificArity, IRScope method, IRubyObject obj) { RubyClass rubyClass = checkClassForDef(context, method, obj); rubyClass.addMethod(method.getId(), new CompiledIRMethod(variable, specific, specificArity, method, Visibility.PUBLIC, rubyClass)); if (!rubyClass.isRefinement()) obj.callMethod(context, "singleton_method_added", method.getName()); }
new CompiledIRMethod( variable, method.getIRScope(), new CompiledIRMethod( variable, JITCompiler.PUBLIC_LOOKUP.findStatic(sourceClass, context.getSpecificName(), entry.getValue()),
new CompiledIRMethod( variable, method.getIRScope(), new CompiledIRMethod( variable, JITCompiler.PUBLIC_LOOKUP.findStatic(sourceClass, context.getSpecificName(), entry.getValue()),