MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / lua_setlocal

Function lua_setlocal

third-party/lua-5.2.4/src/ldebug.c:178–190  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

176
177
178LUA_API const char *lua_setlocal (lua_State *L, const lua_Debug *ar, int n) {
179 StkId pos = 0; /* to avoid warnings */
180 const char *name;
181 lua_lock(L);
182 swapextra(L);
183 name = findlocal(L, ar->i_ci, n, &pos);
184 if (name)
185 setobjs2s(L, pos, L->top - 1);
186 L->top--; /* pop value */
187 swapextra(L);
188 lua_unlock(L);
189 return name;
190}
191
192
193static void funcinfo (lua_Debug *ar, Closure *cl) {

Callers 1

db_setlocalFunction · 0.70

Calls 2

swapextraFunction · 0.70
findlocalFunction · 0.70

Tested by

no test coverage detected