From dbdc74dc5502c2e05e1c1e2ac894943f418c8431 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Wed, 30 Jun 2021 12:53:21 -0300 Subject: Simplification in the parameters of 'luaD_precall' The parameters 'nresults' and 'delta1', in 'luaD_precall', were never meaningful simultaneously. So, they were combined in a single parameter 'retdel'. --- lvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lvm.c') diff --git a/lvm.c b/lvm.c index 62ff70da..ec83f415 100644 --- a/lvm.c +++ b/lvm.c @@ -1632,7 +1632,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) { L->top = ra + b; /* top signals number of arguments */ /* else previous instruction set top */ savepc(L); /* in case of errors */ - if ((newci = luaD_precall(L, ra, nresults, 0)) == NULL) + if ((newci = luaD_precall(L, ra, nresults)) == NULL) updatetrap(ci); /* C call; nothing else to be done */ else { /* Lua call: run function in this same C frame */ ci = newci; @@ -1654,7 +1654,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) { lua_assert(L->tbclist < base); /* no pending tbc variables */ lua_assert(base == ci->func + 1); } - if (luaD_precall(L, ra, LUA_MULTRET, delta + 1)) /* Lua function? */ + if (luaD_precall(L, ra, delta2retdel(delta))) /* Lua function? */ goto startfunc; /* execute the callee */ else { /* C function */ updatetrap(ci); -- cgit v1.2.3-55-g6feb