lua-users home
lua-l archive

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


Tuomo Valkonen wrote:

On Tue, Jun 17, 2003 at 08:48:59PM +0400, Grisha wrote:

Connecting the C++ object to the
table isn't difficult - there's just a field in teh table "__handle" that
stores light user data pointer to the object,


<OT>
This common method of passing objects directly as light userdatas to
Lua makes me see red.


This of course depends on the application. In my app, it is certain that
the objects, which are given to Lua as light userdata pointers, will
not go away while the Lua code is "live".

For a situation were objects might be destroyed, some other method is needed.



		Eero