| 537 | |
| 538 | |
| 539 | static int searcher_Lua (lua_State *L) { |
| 540 | const char *filename; |
| 541 | const char *name = luaL_checkstring(L, 1); |
| 542 | filename = findfile(L, name, "path", LUA_LSUBSEP); |
| 543 | if (filename == NULL) return 1; /* module not found in this path */ |
| 544 | return checkload(L, (luaL_loadfile(L, filename) == LUA_OK), filename); |
| 545 | } |
| 546 | |
| 547 | |
| 548 | /* |
nothing calls this directly
no test coverage detected