lua-users home
lua-l archive

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


> the problem is that [luaL_checkudata] this function actually needs to
> create a new string in order to do the user data name check at all.

If that is a problem for your application, just write your
own luaL_checkudata and luaL_newmetatable. You can for
instance use void* instead of strings and use a static address
in your library. Lua Socket does or planned to do that:
	http://lua-users.org/lists/lua-l/2008-02/msg01282.html

See also these threads
	http://lua-users.org/lists/lua-l/2008-02/msg01246.html
	http://lua-users.org/lists/lua-l/2004-08/msg00497.html