add logical or and logical and

This commit is contained in:
r4
2021-12-23 21:42:09 +01:00
parent d67008cfbf
commit 6bdc4e3210
8 changed files with 53 additions and 9 deletions

2
vm.c
View File

@@ -67,6 +67,8 @@ void run(const IRToks *ir, const BuiltinFunc *builtin_funcs) {
case IREq:
case IRLt:
case IRLe:
case IRAnd:
case IROr:
stack_fit(&s, instr->Binary.addr);
TRY_ELSE(s.mem[instr->Binary.addr] = eval_binary(instr->instr,
irparam_to_val(&s, &instr->Binary.lhs),