mirror of
https://github.com/lua/lua
synced 2026-09-27 00:28:25 +03:00
Small cleaning services
This commit is contained in:
parent
53dc5a3bba
commit
dd095677e3
3 changed files with 46 additions and 30 deletions
3
lfunc.c
3
lfunc.c
|
|
@ -196,8 +196,7 @@ void luaF_unlinkupval (UpVal *uv) {
|
|||
*/
|
||||
void luaF_closeupval (lua_State *L, StkId level) {
|
||||
UpVal *uv;
|
||||
StkId upl; /* stack index pointed by 'uv' */
|
||||
while ((uv = L->openupval) != NULL && (upl = uplevel(uv)) >= level) {
|
||||
while ((uv = L->openupval) != NULL && uplevel(uv) >= level) {
|
||||
TValue *slot = &uv->u.value; /* new position for value */
|
||||
lua_assert(uplevel(uv) < L->top.p);
|
||||
luaF_unlinkupval(uv); /* remove upvalue from 'openupval' list */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue