void executeExponentialIntInt(Executer &executer) { auto y = executer.topInt(); executer.pop(); auto x = executer.topInt(); executer.setTop(PowerIntInt{executer, x, y}()); }
void executeExponentialIntDbl(Executer &executer) { auto y = executer.topDbl(); executer.pop(); auto x = executer.topIntAsDbl(); calculatePowerDblDbl(executer, x, y); }
inline int32_t popIntegerDivisor(Executer &executer) { auto rhs = executer.topInt(); checkDivideByZero(executer, rhs); executer.pop(); return rhs; }
inline double popDoubleDivisor(Executer &executer) { auto rhs = executer.topDbl(); checkDivideByZero(executer, rhs); executer.pop(); return rhs; }
void executeCatTmpTmp(Executer &executer) { auto rhs = executer.moveTopTmpStr(); executer.pop(); *executer.topTmpStr() += *rhs; }
void executeMultiplyIntDbl(Executer &executer) { auto rhs = executer.topDbl(); executer.pop(); auto lhs = executer.topIntAsDbl(); multiplyAndCheckResult(executer, lhs, rhs); }
void executeCatStrStr(Executer &executer) { auto rhs = executer.topStr(); executer.pop(); executer.setTop(*executer.topStr()); *executer.topTmpStr() += *rhs; }
void executeSubtractDblDbl(Executer &executer) { auto rhs = executer.topDbl(); executer.pop(); auto result = executer.topDbl() - rhs; checkDoubleOverflow(executer, result); executer.setTop(result); }
void executeSubtractIntInt(Executer &executer) { auto rhs = executer.topInt(); executer.pop(); auto result = int64_t{executer.topInt()}; result -= rhs; checkIntegerOverflow(executer, result); executer.setTopIntFromInt64(result); }
void executeCatStrTmp(Executer &executer) { auto rhs_result = executer.topTmpStr(); executer.pop(); auto lhs_rhs = std::string{*executer.topStr()}; std::swap(lhs_rhs, *rhs_result); executer.setTop(rhs_result); *executer.topTmpStr() += lhs_rhs; }
void executeImp(Executer &executer) { auto rhs = executer.topInt(); executer.pop(); executer.setTop(~executer.topInt() | rhs); }
void executeEqv(Executer &executer) { auto rhs = executer.topInt(); executer.pop(); executer.setTop(~(executer.topInt() ^ rhs)); }
void executeXor(Executer &executer) { auto rhs = executer.topInt(); executer.pop(); executer.setTop(executer.topInt() ^ rhs); }
void executeAnd(Executer &executer) { auto rhs = executer.topInt(); executer.pop(); executer.setTop(executer.topInt() & rhs); }
void executeAddDblInt(Executer &executer) { auto rhs = executer.topIntAsDbl(); executer.pop(); executer.setTop(executer.topDbl() + rhs); }
void executeSubtractDblInt(Executer &executer) { auto rhs = executer.topIntAsDbl(); executer.pop(); executer.setTop(executer.topDbl() - rhs); }
inline void doDoubleMultiply(Executer &executer, double rhs) { executer.pop(); auto lhs = executer.topDbl(); multiplyAndCheckResult(executer, lhs, rhs); }