lua-users home
lua-l archive

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

>2) I'd change the default number type from double to float.  Yeah, yeah,
>I know I can #define it, but the truth is, it doesn't work in Lua 4.1
>Alpha.  :)  (Amped crashes...)

>4) I'd also have a 32-bit void pointer type.  Amped doesn't use Lua
>userdata, because the cost of the allocation and subsequent garbage
>collection for a simple pointer passthrough (C->Lua->C callback) is too
>high.  Instead, it takes advantage of the precision of the double type
>to pass memory pointers to Lua and back up to C.

Perhaps this is exactly why Amped crashes with 32-bit floats? because 
your passed-through pointers get corrupted?

Just a thought,