lua-users home
lua-l archive

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


Mike Pall wrote:
#if LUA_VERSION_NUM > 50002 (this does not work with the actual value 501)


Well, you are right. But this is not a valid signed integer
constant for CPP on 16 bit systems (yes, Lua compiles there
just fine).
Are there also 8 bit systems where Lua compiles
(maybe on some micro controllers)?


Of course an extra define for the bug fix release number would
work (initially being set to 0).

O.K., seems that LUA_VERSION_NUM already has the right value
(501 for 5.01), and the current macro system doesn't allow to
distinct between bug fix releases.

Thus the post is a suggestion for a additional feature.

Maybe it is worth to think about the macro names when adding
a bug fix version macro, e.g.:

LUA_VERSION_NUM            and  LUA_VERSION_BUGFIX__NUM or
LUA_MAJOR_VERSION_NUM      and  LUA_MINOR_VERSION_NUM   or
LUA_LUANGUAGE_VERSION_NUM  and  LUA_IMPL_VERSION__NUM   or
....

Cheers,
Peter