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

Function opencheck

third-party/lua-5.5.0/src/liolib.c:260–265  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

258
259
260static void opencheck (lua_State *L, const char *fname, const char *mode) {
261 LStream *p = newfile(L);
262 p->f = fopen(fname, mode);
263 if (l_unlikely(p->f == NULL))
264 luaL_error(L, "cannot open file '%s' (%s)", fname, strerror(errno));
265}
266
267
268static int io_open (lua_State *L) {

Callers 2

g_iofileFunction · 0.70
io_linesFunction · 0.70

Calls 2

newfileFunction · 0.70
luaL_errorFunction · 0.70

Tested by

no test coverage detected