diff options
| -rw-r--r-- | lbitlib.c | 5 | ||||
| -rw-r--r-- | linit.c | 8 |
2 files changed, 7 insertions, 6 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lbitlib.c,v 1.24 2014/03/18 18:27:08 roberto Exp roberto $ | 2 | ** $Id: lbitlib.c,v 1.25 2014/03/20 19:22:16 roberto Exp roberto $ |
| 3 | ** Standard library for bitwise operations | 3 | ** Standard library for bitwise operations |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -221,8 +221,7 @@ LUAMOD_API int luaopen_bit32 (lua_State *L) { | |||
| 221 | 221 | ||
| 222 | 222 | ||
| 223 | LUAMOD_API int luaopen_bit32 (lua_State *L) { | 223 | LUAMOD_API int luaopen_bit32 (lua_State *L) { |
| 224 | lua_pushnil(L); | 224 | return luaL_error(L, "library 'bit32' has been deprecated"); |
| 225 | return 1; | ||
| 226 | } | 225 | } |
| 227 | 226 | ||
| 228 | #endif /* } */ | 227 | #endif /* } */ |
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: linit.c,v 1.32 2011/04/08 19:17:36 roberto Exp roberto $ | 2 | ** $Id: linit.c,v 1.33 2014/02/06 17:32:33 roberto Exp roberto $ |
| 3 | ** Initialization of libraries for lua.c and other clients | 3 | ** Initialization of libraries for lua.c and other clients |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -34,10 +34,12 @@ static const luaL_Reg loadedlibs[] = { | |||
| 34 | {LUA_IOLIBNAME, luaopen_io}, | 34 | {LUA_IOLIBNAME, luaopen_io}, |
| 35 | {LUA_OSLIBNAME, luaopen_os}, | 35 | {LUA_OSLIBNAME, luaopen_os}, |
| 36 | {LUA_STRLIBNAME, luaopen_string}, | 36 | {LUA_STRLIBNAME, luaopen_string}, |
| 37 | {LUA_UTF8LIBNAME, luaopen_utf8}, | ||
| 38 | {LUA_BITLIBNAME, luaopen_bit32}, | ||
| 39 | {LUA_MATHLIBNAME, luaopen_math}, | 37 | {LUA_MATHLIBNAME, luaopen_math}, |
| 40 | {LUA_DBLIBNAME, luaopen_debug}, | 38 | {LUA_DBLIBNAME, luaopen_debug}, |
| 39 | {LUA_UTF8LIBNAME, luaopen_utf8}, | ||
| 40 | #if defined(LUA_COMPAT_BITLIB) | ||
| 41 | {LUA_BITLIBNAME, luaopen_bit32}, | ||
| 42 | #endif | ||
| 41 | {NULL, NULL} | 43 | {NULL, NULL} |
| 42 | }; | 44 | }; |
| 43 | 45 | ||
