MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / tableSetMetatable

Method tableSetMetatable

source/core/StarLua.cpp:905–912  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

903}
904
905void LuaEngine::tableSetMetatable(int handleIndex, LuaTable const& table) {
906 lua_checkstack(m_state, 2);
907
908 pushHandle(m_state, handleIndex);
909 pushHandle(m_state, table.handleIndex());
910 lua_setmetatable(m_state, -2);
911 lua_pop(m_state, 1);
912}
913
914void LuaEngine::setContextRequire(int handleIndex, LuaContext::RequireFunction requireFunction) {
915 lua_checkstack(m_state, 4);

Callers 1

setMetatableMethod · 0.80

Calls 3

lua_checkstackFunction · 0.85
lua_setmetatableFunction · 0.85
handleIndexMethod · 0.80

Tested by

no test coverage detected