pop moves value into the register at arg1

cool
This commit is contained in:
2023-05-31 20:41:10 +02:00
parent 66a49c9d1a
commit c176800357

View File

@@ -198,12 +198,17 @@ void push() {
}
void pop() {
if (!is_reg(args->arg1)) {
last_check_args_code = ARG1_WRONG;
return;
}
if (top == -1) { //stack underflow
last_stack_code = UNDERFLOW;
return;
}
--top;
*get_reg(args->arg1) = stack[top--];
}
void and() {