MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / str_reverse

Function str_reverse

Source/Misc/lua/src/lua.c:13734–13742  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13732
13733
13734static int str_reverse (lua_State *L) {
13735size_t l;
13736luaL_Buffer b;
13737const char *s = luaL_checklstring(L, 1, &l);
13738luaL_buffinit(L, &b);
13739while (l--) luaL_addchar(&b, s[l]);
13740luaL_pushresult(&b);
13741return 1;
13742}
13743
13744
13745static int str_lower (lua_State *L) {

Callers

nothing calls this directly

Calls 3

luaL_checklstringFunction · 0.85
luaL_buffinitFunction · 0.85
luaL_pushresultFunction · 0.85

Tested by

no test coverage detected