lua-users home
lua-l archive

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


> If I understand correctly, closure variables in Lua are frozen, ie.
> their values when the closure is defined are fixed.

Actually, we have three types of closures in Lua: C closures (built
via the API call lua_pushcclosure, with constants), Lua closures 4.0
(with upvalues, also constants), and Lua closures 5.0, with "real", live
variables.

-- Roberto