We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 933c5ca commit 97e14f6Copy full SHA for 97e14f6
src/lbaselib.rs
@@ -166,7 +166,11 @@ unsafe extern "C" fn luaB_getmetatable(L: *mut lua_State) -> c_int {
166
}
167
168
unsafe extern "C" fn luaB_setmetatable(L: *mut lua_State) -> c_int {
169
+ let _t = lua_type(L, 2);
170
luaL_checktype(L, 1, LUA_TTABLE);
171
+ // FIXME
172
+ //luaL_argcheck(L, t == LUA_TNIL || t == LUA_TTABLE, 2,
173
+ // "nil or table expected");
174
if luaL_getmetafield(L, 1, cstr!("__metatable")) != LUA_TNIL {
175
luaL_error(L, cstr!("cannot change a protected metatable"));
176
0 commit comments