diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2011-04-08 16:17:36 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2011-04-08 16:17:36 -0300 |
commit | 19fbdf6cae4c5186a498eb7a2fcc128804a9c3d5 (patch) | |
tree | e36890f7302eef1d9bc0eb5199a58b441f2c738c /loadlib.c | |
parent | 427ee519db76b7a0747b5fc1d5dcf97092b5c0bf (diff) | |
download | lua-19fbdf6cae4c5186a498eb7a2fcc128804a9c3d5.tar.gz lua-19fbdf6cae4c5186a498eb7a2fcc128804a9c3d5.tar.bz2 lua-19fbdf6cae4c5186a498eb7a2fcc128804a9c3d5.zip |
'luaL_findtable' -> 'luaL_getsubtable'
Diffstat (limited to 'loadlib.c')
-rw-r--r-- | loadlib.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: loadlib.c,v 1.96 2011/02/07 19:15:24 roberto Exp roberto $ | 2 | ** $Id: loadlib.c,v 1.97 2011/03/01 17:01:53 roberto Exp roberto $ |
3 | ** Dynamic library loader for Lua | 3 | ** Dynamic library loader for Lua |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | ** | 5 | ** |
@@ -652,10 +652,10 @@ LUAMOD_API int luaopen_package (lua_State *L) { | |||
652 | LUA_EXEC_DIR "\n" LUA_IGMARK "\n"); | 652 | LUA_EXEC_DIR "\n" LUA_IGMARK "\n"); |
653 | lua_setfield(L, -2, "config"); | 653 | lua_setfield(L, -2, "config"); |
654 | /* set field `loaded' */ | 654 | /* set field `loaded' */ |
655 | luaL_findtable(L, LUA_REGISTRYINDEX, "_LOADED"); | 655 | luaL_getsubtable(L, LUA_REGISTRYINDEX, "_LOADED"); |
656 | lua_setfield(L, -2, "loaded"); | 656 | lua_setfield(L, -2, "loaded"); |
657 | /* set field `preload' */ | 657 | /* set field `preload' */ |
658 | luaL_findtable(L, LUA_REGISTRYINDEX, "_PRELOAD"); | 658 | luaL_getsubtable(L, LUA_REGISTRYINDEX, "_PRELOAD"); |
659 | lua_setfield(L, -2, "preload"); | 659 | lua_setfield(L, -2, "preload"); |
660 | lua_pushglobaltable(L); | 660 | lua_pushglobaltable(L); |
661 | lua_pushvalue(L, -2); /* set 'package' as upvalue for next lib */ | 661 | lua_pushvalue(L, -2); /* set 'package' as upvalue for next lib */ |