mirror of
https://github.com/LuaJIT/LuaJIT.git
synced 2025-02-07 23:24:09 +00:00
Prevent compile of __concat with tailcall to fast function.
E.g. __concat = function() return setmetatable(...) end Reported by Fezile Manana.
This commit is contained in:
parent
de77205490
commit
75ee3a6159
@ -919,6 +919,9 @@ void lj_record_ret(jit_State *J, BCReg rbase, ptrdiff_t gotresults)
|
||||
TRef tr = gotresults ? J->base[cbase+rbase] : TREF_NIL;
|
||||
if (bslot != J->maxslot) { /* Concatenate the remainder. */
|
||||
TValue *b = J->L->base, save; /* Simulate lower frame and result. */
|
||||
/* Can't handle MM_concat + CALLT + fast func side-effects. */
|
||||
if (J->postproc != LJ_POST_NONE)
|
||||
lj_trace_err(J, LJ_TRERR_NYIRETL);
|
||||
J->base[J->maxslot] = tr;
|
||||
copyTV(J->L, &save, b-(2<<LJ_FR2));
|
||||
if (gotresults)
|
||||
|
Loading…
Reference in New Issue
Block a user