lua-users home
lua-l archive

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

> The luaconf.h now has a #include <math.h> re-introduced. It would seem
> that ldo.c is the only thing that needs this to compile.

lcode.c also needs it now (for constant-expression evaluation; yes,
another novelty in beta...). But the main point is that, if you change
lua_Number (or the definitions of some airthmetic operations), they
may not need math.h anymore. We want to be able to correct that only
changing luaconf.h.

> I compile 2 lua modules as C++(without going into why), this means that
> I change the the lua includes to be wrapped in extern "C" {. This means
> that the math.h definitions/declarations are compiled within the extern
> "C" warpper.  Because math.h and others have conditional code guarded by
> #ifdef __cplusplus This not unsuprisingly generates a lot of compilation
> errors.

As you are already changing those modules, you can include math.h in
them before including the lua headers :)

-- Roberto