@Override public final double applyDouble(double operand) { if (operandNACheck.check(operand)) { return RRuntime.DOUBLE_NA; } try { return arithmetic.op(operand); } catch (Throwable e) { CompilerDirectives.transferToInterpreter(); throw Operation.handleException(e); } }
@Override public final RComplex applyComplex(RComplex operand) { if (operandNACheck.check(operand)) { return RComplex.createNA(); } try { return arithmetic.op(operand.getRealPart(), operand.getImaginaryPart()); } catch (Throwable e) { CompilerDirectives.transferToInterpreter(); throw Operation.handleException(e); } }