MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / f_luaopen

Function f_luaopen

lib/lua/src/lstate.c:231–242  ·  view source on GitHub ↗

** open parts of the state that may cause memory-allocation errors. */

Source from the content-addressed store, hash-verified

229** open parts of the state that may cause memory-allocation errors.
230*/
231static void f_luaopen (lua_State *L, void *ud) {
232 global_State *g = G(L);
233 UNUSED(ud);
234 stack_init(L, L); /* init stack */
235 init_registry(L, g);
236 luaS_init(L);
237 luaT_init(L);
238 luaX_init(L);
239 g->gcstp = 0; /* allow gc */
240 setnilvalue(&g->nilvalue); /* now state is complete */
241 luai_userstateopen(L);
242}
243
244
245/*

Callers

nothing calls this directly

Calls 6

stack_initFunction · 0.85
init_registryFunction · 0.85
luaS_initFunction · 0.85
luaT_initFunction · 0.85
luaX_initFunction · 0.85
GFunction · 0.50

Tested by

no test coverage detected