lua-users home
lua-l archive

Re: Calling back into lua from a gc method -- okay?

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


> Are there any specific limitations in Lua 4.0.1 on what you can do from
> within a C function as registered gc tag method?
Yes!! Don't do anything :-))
In Lua 4.0 the gc tag methods run when Lua is kind of in the middle
of the collection. As a general rule, do as little as possible in Lua
during a gc tag method. More specifically, do not create new objects
(lua_newtable, lua_pushcfunction, etc.).
-- Roberto

AltStyle によって変換されたページ (->オリジナル) /