be a bit more forgiving in eval interpreter, to allow for graceful type (and thus empty bytecode) evaluation

This commit is contained in:
Ryan Fleury committed 2024-08-06 07:15:03 -07:00
1 parent ebaf83172f
commit 784a77bdff
2 files changed
+11 -6

No files matched your search

+1 -6
View File
@@ -5349,15 +5349,10 @@ e_interpret(String8 bytecode)
}
done:;
if(stack_count == 1)
if(stack_count >= 1)
{
result.value = stack[0];
}
else if(result.code == E_InterpretationCode_Good)
{
result.code = E_InterpretationCode_MalformedBytecode;
}
scratch_end(scratch);
return result;
}