lua-users home
lua-l archive

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


> I way just wondering: the current implementation makes use of the numeric
> indexes in the registry table. But lua_ref() and related stuff is here for
> compatibility only (as mentionned in lua.h), meaning that it should not
> remain, right ?

More or less. The macros lua_ref/lua_unref/lua_getref are for
compatibility, but the functions luaL_ref/luaL_unref are not. That is,
Lua keeps a reference mechanism, but now you can choose to put your
stuff into the registry or into a private table of yours (which may be a
weak table, for instance).


-- Roberto