MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / luaD_protectedparser

Function luaD_protectedparser

third-party/lua-5.4.6/src/ldo.c:1016–1033  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1014
1015
1016int luaD_protectedparser (lua_State *L, ZIO *z, const char *name,
1017 const char *mode) {
1018 struct SParser p;
1019 int status;
1020 incnny(L); /* cannot yield during parsing */
1021 p.z = z; p.name = name; p.mode = mode;
1022 p.dyd.actvar.arr = NULL; p.dyd.actvar.size = 0;
1023 p.dyd.gt.arr = NULL; p.dyd.gt.size = 0;
1024 p.dyd.label.arr = NULL; p.dyd.label.size = 0;
1025 luaZ_initbuffer(L, &p.buff);
1026 status = luaD_pcall(L, f_parser, &p, savestack(L, L->top.p), L->errfunc);
1027 luaZ_freebuffer(L, &p.buff);
1028 luaM_freearray(L, p.dyd.actvar.arr, p.dyd.actvar.size);
1029 luaM_freearray(L, p.dyd.gt.arr, p.dyd.gt.size);
1030 luaM_freearray(L, p.dyd.label.arr, p.dyd.label.size);
1031 decnny(L);
1032 return status;
1033}
1034
1035

Callers 1

lua_loadFunction · 0.70

Calls 1

luaD_pcallFunction · 0.70

Tested by

no test coverage detected