[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: lua_newuserdatabox (4.1)
- From: "Curt Carpenter" <curtc@...>
- Date: Wed, 20 Feb 2002 15:15:50 -0800
I was curious as to why the naming of lua_newuserdatabox doesn't follow
the same naming convention as all the lua_push* functions. Tracing
though the code a bit, I was disappointed to discover that
lua_newuserdatabox ends up causing a memory allocation. Can't we please
have a lua_pushuserdata(lua_State *, void *) or the like? I know this
has been discussed already, but at the time my (mis)understanding was
that the new lua_newuserdatabox was lightweight. An allocation just to
pass a simple pointer is going to kill performance. This is the kind of
thing that could cause me to have to significantly scale back the scope
I was planning for Lua to have in my project.
Thanks,
Curt