lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> Lua 5.2.4
> In lgc.c propagatemark -> traversestack, line 502-506,
> clear the slice in the range of [th->top + 1, th->stack + th->stacksize),
> What if don't clear not-marked stack slice ?

Sometimes Lua increates the stack pointer without filling the
corresponding slots (e.g., when entering a Lua funcion and then calling
a metamethod).  This step ensures that the entire stack always has valid
values, so that later gc cycles can always traverse the stack without
problems.

-- Roberto