[qfcc] Prepend state epxression instead of just linking

This fixes an expression loop ICE when building for Ruamoko (not that
there actually was a loop, but the test is rather simplistic).
This commit is contained in:
Bill Currie 2022-01-29 18:57:48 +09:00
parent 49395b3ba1
commit 61727941fd

View file

@ -724,8 +724,7 @@ build_code_function (symbol_t *fsym, expr_t *state_expr, expr_t *statements)
return 0;
build_function (fsym);
if (state_expr) {
state_expr->next = statements;
statements = state_expr;
prepend_expr (statements, state_expr);
}
function_t *func = fsym->s.func;
if (options.code.progsversion == PROG_VERSION) {