MCPcopy Create free account
hub / github.com/DFHack/dfhack / lua_upvaluejoin

Function lua_upvaluejoin

depends/lua/src/lapi.c:1286–1297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1284
1285
1286LUA_API void lua_upvaluejoin (lua_State *L, int fidx1, int n1,
1287 int fidx2, int n2) {
1288 UpVal **up1 = getupvalref(L, fidx1, n1);
1289 UpVal **up2 = getupvalref(L, fidx2, n2);
1290 if (*up1 == *up2)
1291 return;
1292 luaC_upvdeccount(L, *up1);
1293 *up1 = *up2;
1294 (*up1)->refcount++;
1295 if (upisopen(*up1)) (*up1)->u.open.touched = 1;
1296 luaC_upvalbarrier(L, *up1);
1297}
1298
1299

Callers 1

db_upvaluejoinFunction · 0.85

Calls 2

getupvalrefFunction · 0.85
luaC_upvdeccountFunction · 0.85

Tested by

no test coverage detected