MCPcopy Create free account
hub / github.com/BigPig0/RelayLive / str_upper

Function str_upper

ThirdParty/lua/lua/lstrlib.c:104–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

102
103
104static int str_upper (lua_State *L) {
105 size_t l;
106 size_t i;
107 luaL_Buffer b;
108 const char *s = luaL_checklstring(L, 1, &l);
109 char *p = luaL_buffinitsize(L, &b, l);
110 for (i=0; i<l; i++)
111 p[i] = toupper(uchar(s[i]));
112 luaL_pushresultsize(&b, l);
113 return 1;
114}
115
116
117static int str_rep (lua_State *L) {

Callers

nothing calls this directly

Calls 3

luaL_checklstringFunction · 0.85
luaL_buffinitsizeFunction · 0.85
luaL_pushresultsizeFunction · 0.85

Tested by

no test coverage detected