Figured out why that doesn't work

This commit is contained in:
GenericHeroGuy authored and Indev committed 2025-03-03 01:34:24 +03:00
1 parent 40d0d9d2b8
commit 0c2244d668
1 file changed
+6 -6
+6 -6
View File
@@ -782,15 +782,15 @@ static void bcemit_branch_f(FuncState *fs, ExpDesc *e)
{
BCPos pc;
expr_discharge(fs, e);
if (e->k == VKNIL || e->k == VKFALSE
#if LJ_INTONLY
|| (expr_isnumk_nojump(e) && expr_intV(e) == 0)
#endif
)
if (e->k == VKNIL || e->k == VKFALSE)
pc = NO_JMP; /* Never jump. */
else if (e->k == VJMP)
pc = e->u.s.info;
else if (e->k == VKSTR || e->k == VKNUM || e->k == VKTRUE)
else if (e->k == VKSTR || e->k == VKTRUE
#if !LJ_INTONLY
|| e->k == VKNUM
#endif
)
expr_toreg_nobranch(fs, e, NO_REG), pc = bcemit_jmp(fs);
else
pc = bcemit_branch(fs, e, 1);