Beispiel #1
0
  @Override
  public IRubyObject interpret(
      Ruby runtime, ThreadContext context, IRubyObject self, Block aBlock) {
    IRubyObject value = getValueNode().interpret(runtime, context, self, aBlock);

    if (!(value instanceof RubyArray)) {
      value = ArgsUtil.convertToRubyArray19(runtime, value, pre != null);
    }

    return AssignmentVisitor.multiAssign(runtime, context, self, this, (RubyArray) value);
  }
Beispiel #2
0
  @Override
  public IRubyObject assign(
      Ruby runtime,
      ThreadContext context,
      IRubyObject self,
      IRubyObject value,
      Block block,
      boolean checkArity) {
    if (!(value instanceof RubyArray)) {
      value = ArgsUtil.convertToRubyArray19(runtime, value, pre != null);
    }

    return AssignmentVisitor.multiAssign(
        runtime, context, self, this, (RubyArray) value, checkArity);
  }