MCPcopy Create free account
hub / github.com/IppClub/Dora-SSR / executeModule

Method executeModule

Source/Lua/LuaEngine.cpp:1731–1738  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1729}
1730
1731bool LuaEngine::executeModule(String module) {
1732 int top = lua_gettop(L);
1733 DEFER(lua_settop(L, top));
1734 lua_getglobal(L, "require"); // file, require
1735 lua_pushlstring(L, module.c_str(), module.size());
1736 int result = LuaEngine::call(L, 1, 0); // require(module)
1737 return result != 0;
1738}
1739
1740void LuaEngine::pop(int count) {
1741 lua_pop(L, count);

Callers 1

initMethod · 0.80

Calls 6

lua_getglobalFunction · 0.85
lua_gettopFunction · 0.50
lua_settopFunction · 0.50
lua_pushlstringFunction · 0.50
c_strMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected