[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Unique object references
- From: Chris <coderight@...>
- Date: Fri, 8 Dec 2006 19:50:05 -0500
Ah, thanks! Don't know why I didn't think of that. To be honest I
guess I have never seen the output of tostring on a table or function.
Yes it looks like tostring does (hopefully) return what I was looking
On 12/8/06, Jerome Vuarand <email@example.com> wrote:
I think you can use tostring to get a unique string identifier to any
Lua value. You can also put a reference to the values you're interested
in in the registry, which is unique per Lua master state (use luaL_ref
and luaL_unref with LUA_REGISTRYINDEX as second parameter).