lua-users home
lua-l archive

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


Hello everyone.

When publishing some classes I have in my code to Lua I've been using
the trick of setting metatable.__index to the metatable and also
stashing some markers I use ( they are mainly light userdata derived
from the address of auxiliary static objects )

>>From all I've seen / read I think it won't cause problems, and I've
seen the __index thing using in several places, and the lightuserdata
shouldn't pose a problem, as the only normal way to get at them is to
enumerate the table, but I'd like to hear if I've missed something and
I should not be storing "alien" date in there.

So, is there any problem with storing strange things in an object metatable?


Francisco Olarte.