diff options
Diffstat (limited to 'src/lauxlib.h')
-rw-r--r-- | src/lauxlib.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lauxlib.h b/src/lauxlib.h index 91ff4ea9..a8280c20 100644 --- a/src/lauxlib.h +++ b/src/lauxlib.h | |||
@@ -85,6 +85,9 @@ LUALIB_API int (luaL_loadbufferx) (lua_State *L, const char *buff, size_t sz, | |||
85 | const char *name, const char *mode); | 85 | const char *name, const char *mode); |
86 | LUALIB_API void luaL_traceback (lua_State *L, lua_State *L1, const char *msg, | 86 | LUALIB_API void luaL_traceback (lua_State *L, lua_State *L1, const char *msg, |
87 | int level); | 87 | int level); |
88 | LUALIB_API void (luaL_setfuncs) (lua_State *L, const luaL_Reg *l, int nup); | ||
89 | LUALIB_API void (luaL_pushmodule) (lua_State *L, const char *modname, | ||
90 | int sizehint); | ||
88 | 91 | ||
89 | 92 | ||
90 | /* | 93 | /* |
@@ -114,6 +117,11 @@ LUALIB_API void luaL_traceback (lua_State *L, lua_State *L1, const char *msg, | |||
114 | 117 | ||
115 | #define luaL_opt(L,f,n,d) (lua_isnoneornil(L,(n)) ? (d) : f(L,(n))) | 118 | #define luaL_opt(L,f,n,d) (lua_isnoneornil(L,(n)) ? (d) : f(L,(n))) |
116 | 119 | ||
120 | /* From Lua 5.2. */ | ||
121 | #define luaL_newlibtable(L, l) \ | ||
122 | lua_createtable(L, 0, sizeof(l)/sizeof((l)[0]) - 1) | ||
123 | #define luaL_newlib(L, l) (luaL_newlibtable(L, l), luaL_setfuncs(L, l, 0)) | ||
124 | |||
117 | /* | 125 | /* |
118 | ** {====================================================== | 126 | ** {====================================================== |
119 | ** Generic Buffer manipulation | 127 | ** Generic Buffer manipulation |