MCPcopy Create free account
hub / github.com/Achain-Dev/Achain / pushnexttemplate

Function pushnexttemplate

src/Chain/libraries/glua/loadlib.cpp:390–398  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

388
389
390static const char *pushnexttemplate(lua_State *L, const char *path) {
391 const char *l;
392 while (*path == *LUA_PATH_SEP) path++; /* skip separators */
393 if (*path == '\0') return nullptr; /* no more templates */
394 l = strchr(path, *LUA_PATH_SEP); /* find next separator */
395 if (l == nullptr) l = path + strlen(path);
396 lua_pushlstring(L, path, l - path); /* template */
397 return l;
398}
399
400
401static const char *searchpath(lua_State *L, const char *name,

Callers 1

searchpathFunction · 0.85

Calls 1

lua_pushlstringFunction · 0.85

Tested by

no test coverage detected