@Override public Instr clone(CloneInfo ii) { return new OneOperandArgNoBlockNoResultCallInstr(ii.getScope(), getCallType(), getName(), getReceiver().cloneForInlining(ii), cloneCallArgs(ii), getClosureArg() == null ? null : getClosureArg().cloneForInlining(ii), isPotentiallyRefined(), getCallSite(), getCallSiteId()); }
@Override public Object interpret(ThreadContext context, StaticScope currScope, DynamicScope dynamicScope, IRubyObject self, Object[] temp) { IRubyObject object = (IRubyObject) getReceiver().retrieve(context, self, currScope, dynamicScope, temp); IRubyObject arg1 = (IRubyObject) getArg1().retrieve(context, self, currScope, dynamicScope, temp); return getCallSite().call(context, self, object, arg1); } }
public Operand getArg1() { return getCallArgs()[0]; }
@Override public Object interpret(ThreadContext context, DynamicScope dynamicScope, IRubyObject self, Object[] temp, Block block) { IRubyObject object = (IRubyObject) receiver.retrieve(context, self, dynamicScope, temp); IRubyObject arg1 = (IRubyObject) getCallArgs()[0].retrieve(context, self, dynamicScope, temp); return getCallSite().call(context, self, object, arg1); } }
public static NoResultCallInstr create(IRScope scope, CallType callType, RubySymbol name, Operand receiver, Operand[] args, Operand closure, boolean isPotentiallyRefined) { if (closure == null && !containsArgSplat(args) && args.length == 1) { return new OneOperandArgNoBlockNoResultCallInstr(scope, callType, name, receiver, args, null, isPotentiallyRefined); } return new NoResultCallInstr(scope, Operation.NORESULT_CALL, callType, name, receiver, args, closure, isPotentiallyRefined); }
@Override public Object interpret(ThreadContext context, DynamicScope dynamicScope, IRubyObject self, Object[] temp, Block block) { IRubyObject object = (IRubyObject) receiver.retrieve(context, self, dynamicScope, temp); IRubyObject arg1 = (IRubyObject) getCallArgs()[0].retrieve(context, self, dynamicScope, temp); return getCallSite().call(context, self, object, arg1); } }
public static NoResultCallInstr create(IRScope scope, CallType callType, RubySymbol name, Operand receiver, Operand[] args, Operand closure, boolean isPotentiallyRefined) { if (closure == null && !containsArgSplat(args) && args.length == 1) { return new OneOperandArgNoBlockNoResultCallInstr(scope, callType, name, receiver, args, null, isPotentiallyRefined); } return new NoResultCallInstr(scope, Operation.NORESULT_CALL, callType, name, receiver, args, closure, isPotentiallyRefined); }
@Override public Instr clone(CloneInfo ii) { return new OneOperandArgNoBlockNoResultCallInstr(ii.getScope(), getCallType(), getName(), getReceiver().cloneForInlining(ii), cloneCallArgs(ii), getClosureArg() == null ? null : getClosureArg().cloneForInlining(ii), isPotentiallyRefined(), getCallSite(), getCallSiteId()); }
@Override public Object interpret(ThreadContext context, StaticScope currScope, DynamicScope dynamicScope, IRubyObject self, Object[] temp) { IRubyObject object = (IRubyObject) getReceiver().retrieve(context, self, currScope, dynamicScope, temp); IRubyObject arg1 = (IRubyObject) getArg1().retrieve(context, self, currScope, dynamicScope, temp); return getCallSite().call(context, self, object, arg1); } }
@Override public CallBase specializeForInterpretation() { Operand[] callArgs = getCallArgs(); if (hasClosure() || containsSplat(callArgs)) return this; switch (callArgs.length) { // case 0: // return new ZeroOperandArgNoBlockNoResultCallInstr(this); case 1: // if (isAllFixnums()) return new OneFixnumArgNoBlockNoResultCallInstr(this); return new OneOperandArgNoBlockNoResultCallInstr(this); } return this; }
public Operand getArg1() { return getCallArgs()[0]; }
IRubyObject r = (IRubyObject)retrieveOp(call.getReceiver(), context, self, currDynScope, temp); IRubyObject o = (IRubyObject)call.getArg1().retrieve(context, self, currDynScope, temp); call.getCallSite().call(context, self, r, o); break;
@Override public CallBase specializeForInterpretation() { Operand[] callArgs = getCallArgs(); if (hasClosure() || containsSplat(callArgs)) return this; switch (callArgs.length) { // case 0: // return new ZeroOperandArgNoBlockNoResultCallInstr(this); case 1: // if (isAllFixnums()) return new OneFixnumArgNoBlockNoResultCallInstr(this); return new OneOperandArgNoBlockNoResultCallInstr(this); } return this; }
IRubyObject r = (IRubyObject)retrieveOp(call.getReceiver(), context, self, currDynScope, temp); IRubyObject o = (IRubyObject)call.getArg1().retrieve(context, self, currDynScope, temp); call.getCallSite().call(context, self, r, o); break;
IRubyObject r = (IRubyObject)retrieveOp(call.getReceiver(), context, self, currDynScope, currScope, temp); IRubyObject o = (IRubyObject)call.getArg1().retrieve(context, self, currScope, currDynScope, temp); call.getCallSite().call(context, self, r, o); break;
IRubyObject r = (IRubyObject)retrieveOp(call.getReceiver(), context, self, currDynScope, currScope, temp); IRubyObject o = (IRubyObject)call.getArg1().retrieve(context, self, currScope, currDynScope, temp); call.getCallSite().call(context, self, r, o); break;