1
0
mirror of https://github.com/lua/lua.git synced 2025-01-28 06:03:00 +08:00

detail (cast to avoid mixing types in conditional expression)

This commit is contained in:
Roberto Ierusalimschy 2015-06-25 11:00:01 -03:00
parent 5aabb7a891
commit f01c12c891

4
lvm.c
View File

@ -1,5 +1,5 @@
/*
** $Id: lvm.c,v 2.244 2015/06/02 19:11:24 roberto Exp roberto $
** $Id: lvm.c,v 2.245 2015/06/09 15:53:35 roberto Exp roberto $
** Lua virtual machine
** See Copyright Notice in lua.h
*/
@ -1125,7 +1125,7 @@ void luaV_execute (lua_State *L) {
vmcase(OP_RETURN) {
int b = GETARG_B(i);
if (cl->p->sizep > 0) luaF_close(L, base);
b = luaD_poscall(L, ra, (b != 0 ? b - 1 : L->top - ra));
b = luaD_poscall(L, ra, (b != 0 ? b - 1 : cast_int(L->top - ra)));
if (!(ci->callstatus & CIST_REENTRY)) /* 'ci' still the called one */
return; /* external invocation: return */
else { /* invocation via reentry: continue execution */