| 498 | |
| 499 | |
| 500 | static int searcher_Lua (lua_State *L) { |
| 501 | const char *filename; |
| 502 | const char *name = luaL_checkstring(L, 1); |
| 503 | filename = findfile(L, name, "path", LUA_LSUBSEP); |
| 504 | if (filename == NULL) return 1; /* module not found in this path */ |
| 505 | return checkload(L, (luaL_loadfile(L, filename) == LUA_OK), filename); |
| 506 | } |
| 507 | |
| 508 | |
| 509 | /* |
no test coverage detected