| 408 | |
| 409 | |
| 410 | static int searcher_Lua (lua_State *L) { |
| 411 | const char *filename; |
| 412 | const char *name = luaL_checkstring(L, 1); |
| 413 | filename = findfile(L, name, "path", LUA_LSUBSEP); |
| 414 | if (filename == NULL) return 1; /* module not found in this path */ |
| 415 | return checkload(L, (luaL_loadfile(L, filename) == LUA_OK), filename); |
| 416 | } |
| 417 | |
| 418 | |
| 419 | static int loadfunc (lua_State *L, const char *filename, const char *modname) { |
nothing calls this directly
no test coverage detected