1
0
mirror of https://github.com/dschmenk/PLASMA.git synced 2025-01-07 00:29:34 +00:00
This commit is contained in:
David Schmenk 2024-07-07 21:23:47 -07:00
parent 5ad6b0733c
commit 5e3baa70fb

View File

@ -721,6 +721,16 @@ def natv_rem(expr)
return new_int(num[0], num[1])
end
def natv_neg(expr)
var num[2]
num[0], num[1] = eval_num(expr)
load32(@num)
neg32
store32(@num)
return new_int(num[0], num[1])
end
def natv_gt(expr)
var num[2]
@ -780,6 +790,7 @@ def install_defaults#0
new_sym("*")=>natv = @natv_mul)
new_sym("/")=>natv = @natv_div)
new_sym("REM")=>natv = @natv_rem)
new_sym("NEG")=>natv = @natv_neg)
new_sym(">")=>natv = @natv_gt)
new_sym("<")=>natv = @natv_lt)
new_sym("PRINT")=>natv = @natv_print)