mirror of
https://github.com/lua/lua.git
synced 2026-06-08 08:03:49 +00:00
new macro 'setnilvalue2s'
This commit is contained in:
2
lvm.c
2
lvm.c
@@ -303,7 +303,7 @@ lu_byte luaV_finishget (lua_State *L, const TValue *t, TValue *key,
|
||||
else { /* 't' is a table */
|
||||
tm = fasttm(L, hvalue(t)->metatable, TM_INDEX); /* table's metamethod */
|
||||
if (tm == NULL) { /* no metamethod? */
|
||||
setnilvalue(s2v(val)); /* result is nil */
|
||||
setnilvalue2s(val); /* result is nil */
|
||||
return LUA_VNIL;
|
||||
}
|
||||
/* else will try the metamethod */
|
||||
|
||||
Reference in New Issue
Block a user