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

Function handle_script

third-party/lua-5.5.0/src/lua.c:258–269  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

256
257
258static int handle_script (lua_State *L, char **argv) {
259 int status;
260 const char *fname = argv[0];
261 if (strcmp(fname, "-") == 0 && strcmp(argv[-1], "--") != 0)
262 fname = NULL; /* stdin */
263 status = luaL_loadfile(L, fname);
264 if (status == LUA_OK) {
265 int n = pushargs(L); /* push arguments to script */
266 status = docall(L, n, LUA_MULTRET);
267 }
268 return report(L, status);
269}
270
271
272/* bits of various argument indicators in 'args' */

Callers 1

pmainFunction · 0.70

Calls 4

luaL_loadfileFunction · 0.85
pushargsFunction · 0.70
docallFunction · 0.70
reportFunction · 0.70

Tested by

no test coverage detected