lua-users home
lua-l archive

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


> But presumably everything has to be checked at somepoint which will result
> in the same problems as are being encountered now?

Old immutable objects are only "checked" at full collections. Usually
you have to run a full collection from time to time, but this is much
less frequent than "short" collections. For some particular tunned
applications, you can completely avoid full collections.


> Would adding a "const"/"static" keyword help?

Lua still have to check that nobody changes such objects, so the overhead
would be similar (small in both cases). But with a generational collection
Lua would detect those "const" objects for you.

-- Roberto