lua-users home
lua-l archive

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


It seems that too many people are having problems with this DirectX issue.
How can we solve that??

- Some people suggested adding some warning in the manual. Would this
really help? I mean, if you find an unexpected bug in a program, where
will you search for help? In the manual? In what section?

- Another option would be to simply turn off the offending macro
(lua_number2int) in Windows. This will slow down Lua a bit... Of
course, anyone is free to use it, but the default would avoid the
problem. (Doesn't Windows offer lrint? Could we use it instead?)

- Other option would be to add a check somewhere in the code, so
that this situation is detected early and gives a proper error message.
(Unfortunately, the test cannot be when creating a Lua state, because
there is no way to return an error message. Maybe when loading a chunk?)

-- Roberto