diff options
Diffstat (limited to 'lauxlib.c')
| -rw-r--r-- | lauxlib.c | 2 |
1 files changed, 1 insertions, 1 deletions
| @@ -902,10 +902,10 @@ LUALIB_API const char *luaL_tolstring (lua_State *L, int idx, size_t *len) { | |||
| 902 | LUALIB_API void luaL_setfuncs (lua_State *L, const luaL_Reg *l, int nup) { | 902 | LUALIB_API void luaL_setfuncs (lua_State *L, const luaL_Reg *l, int nup) { |
| 903 | luaL_checkstack(L, nup, "too many upvalues"); | 903 | luaL_checkstack(L, nup, "too many upvalues"); |
| 904 | for (; l->name != NULL; l++) { /* fill the table with given functions */ | 904 | for (; l->name != NULL; l++) { /* fill the table with given functions */ |
| 905 | int i; | ||
| 906 | if (l->func == NULL) /* place holder? */ | 905 | if (l->func == NULL) /* place holder? */ |
| 907 | lua_pushboolean(L, 0); | 906 | lua_pushboolean(L, 0); |
| 908 | else { | 907 | else { |
| 908 | int i; | ||
| 909 | for (i = 0; i < nup; i++) /* copy upvalues to the top */ | 909 | for (i = 0; i < nup; i++) /* copy upvalues to the top */ |
| 910 | lua_pushvalue(L, -nup); | 910 | lua_pushvalue(L, -nup); |
| 911 | lua_pushcclosure(L, l->func, nup); /* closure with those upvalues */ | 911 | lua_pushcclosure(L, l->func, nup); /* closure with those upvalues */ |
