MCPcopy Create free account
hub / github.com/DFHack/dfhack / checkmode

Function checkmode

depends/lua/src/ldo.c:757–763  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

755
756
757static void checkmode (lua_State *L, const char *mode, const char *x) {
758 if (mode && strchr(mode, x[0]) == NULL) {
759 luaO_pushfstring(L,
760 "attempt to load a %s chunk (mode is '%s')", x, mode);
761 luaD_throw(L, LUA_ERRSYNTAX);
762 }
763}
764
765
766static void f_parser (lua_State *L, void *ud) {

Callers 1

f_parserFunction · 0.85

Calls 2

luaO_pushfstringFunction · 0.85
luaD_throwFunction · 0.85

Tested by

no test coverage detected