diff options
author | 2017-02-05 16:17:00 +0100 | |
---|---|---|
committer | 2017-02-05 16:17:00 +0100 | |
commit | e6838eb5c4e2da8244d6935633dfcb683256c044 (patch) | |
tree | 7be667ded2a2a33b6361f8a2f9e0d7ee86b62264 /3rdparty/lua/src/lbaselib.c | |
parent | 8d1eb8e410f18bd20f8bb0ac68826bce9c32e635 (diff) |
LUA to 5.3.4 (nw)
Diffstat (limited to '3rdparty/lua/src/lbaselib.c')
-rw-r--r-- | 3rdparty/lua/src/lbaselib.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/3rdparty/lua/src/lbaselib.c b/3rdparty/lua/src/lbaselib.c index d481c4e1ef4..08523e6e754 100644 --- a/3rdparty/lua/src/lbaselib.c +++ b/3rdparty/lua/src/lbaselib.c @@ -1,5 +1,5 @@ /* -** $Id: lbaselib.c,v 1.313 2016/04/11 19:18:40 roberto Exp $ +** $Id: lbaselib.c,v 1.314 2016/09/05 19:06:34 roberto Exp $ ** Basic library ** See Copyright Notice in lua.h */ @@ -208,8 +208,8 @@ static int luaB_type (lua_State *L) { static int pairsmeta (lua_State *L, const char *method, int iszero, lua_CFunction iter) { + luaL_checkany(L, 1); if (luaL_getmetafield(L, 1, method) == LUA_TNIL) { /* no metamethod? */ - luaL_checktype(L, 1, LUA_TTABLE); /* argument must be a table */ lua_pushcfunction(L, iter); /* will return generator, */ lua_pushvalue(L, 1); /* state, */ if (iszero) lua_pushinteger(L, 0); /* and initial value */ |