mirror of
https://github.com/janet-lang/janet
synced 2024-12-24 07:20:27 +00:00
Address issues from #1294 on non-nanboxed platforms.
Underlying bug was obscured by nanbox implementation.
This commit is contained in:
parent
910b9cf1fd
commit
7b4c3bdbcc
@ -861,7 +861,7 @@ static JanetSignal run_vm(JanetFiber *fiber, Janet in) {
|
|||||||
vm_pcnext();
|
vm_pcnext();
|
||||||
|
|
||||||
VM_OP(JOP_EQUALS_IMMEDIATE)
|
VM_OP(JOP_EQUALS_IMMEDIATE)
|
||||||
stack[A] = janet_wrap_boolean(janet_unwrap_number(stack[B]) == (double) CS);
|
stack[A] = janet_wrap_boolean(janet_checktype(stack[B], JANET_NUMBER) && (janet_unwrap_number(stack[B]) == (double) CS));
|
||||||
vm_pcnext();
|
vm_pcnext();
|
||||||
|
|
||||||
VM_OP(JOP_NOT_EQUALS)
|
VM_OP(JOP_NOT_EQUALS)
|
||||||
@ -869,7 +869,7 @@ static JanetSignal run_vm(JanetFiber *fiber, Janet in) {
|
|||||||
vm_pcnext();
|
vm_pcnext();
|
||||||
|
|
||||||
VM_OP(JOP_NOT_EQUALS_IMMEDIATE)
|
VM_OP(JOP_NOT_EQUALS_IMMEDIATE)
|
||||||
stack[A] = janet_wrap_boolean(janet_unwrap_number(stack[B]) != (double) CS);
|
stack[A] = janet_wrap_boolean(!janet_checktype(stack[B], JANET_NUMBER) || (janet_unwrap_number(stack[B]) != (double) CS));
|
||||||
vm_pcnext();
|
vm_pcnext();
|
||||||
|
|
||||||
VM_OP(JOP_COMPARE)
|
VM_OP(JOP_COMPARE)
|
||||||
|
Loading…
Reference in New Issue
Block a user