Skip to content
Snippets Groups Projects
Commit 08c772a2 authored by gambas's avatar gambas
Browse files

Fix FOR EACH loops translation.

[GB.JIT]
* BUG: Panic if the stack is not void once a function has been translated.
* BUG: Fix FOR EACH loops translation.
parent b8198005
No related branches found
No related tags found
No related merge requests found
Pipeline #23790279 failed
......@@ -107,10 +107,7 @@ static bool end(FUNCTION *func, int index)
GB.FreeArray((void **)&_ctrl_type);
if (_stack_current)
{
fprintf(stderr, "gb.jit: warning: stack mismatch! (%d)\n", _stack_current);
_stack_current = 0;
}
JIT_panic("Stack mismatch: stack is not void");
return FALSE;
}
......@@ -140,7 +137,7 @@ static void free_stack(int n)
static void check_stack(int n)
{
if (_stack_current < n)
JIT_panic("Stack mismatch");
JIT_panic("Stack mismatch: stack is void");
}
......@@ -2341,6 +2338,7 @@ _ENUM_NEXT:
if ((code & 1) == 0)
push(T_UNKNOWN, "POP_u()");
p++;
goto _MAIN;
_PUSH_CONST:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment