MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / db_setmetatable

Function db_setmetatable

deps/lua/src/ldblib.c:37–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35
36
37static int db_setmetatable (lua_State *L) {
38 int t = lua_type(L, 2);
39 luaL_argcheck(L, t == LUA_TNIL || t == LUA_TTABLE, 2,
40 "nil or table expected");
41 lua_settop(L, 2);
42 lua_pushboolean(L, lua_setmetatable(L, 1));
43 return 1;
44}
45
46
47static int db_getfenv (lua_State *L) {

Callers

nothing calls this directly

Calls 4

lua_typeFunction · 0.85
lua_settopFunction · 0.85
lua_pushbooleanFunction · 0.85
lua_setmetatableFunction · 0.85

Tested by

no test coverage detected