lua-users home
lua-l archive

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


On 09/07/2013 18.36, Roberto Ierusalimschy wrote:
Just for curiosity: what is the rationale behind this version bump
with this new "int" transparent mechanism? It seems that it
complicates the innards of Lua a lot and appears useful mostly for
people working with some "float hostile" environments.

As other people already answered, the first rationale was to offer
64-bit integers, with a close second to help "float hostile"
environments (an area where Lua is growing).


Wouldn't have
been easier to improve support for int types at compile time for
people needing Lua working with an int number type instead?

Many people that need Lua working with int numbers miss support
for floating points. Moreover, that creates two very different
versions of Lua (only floats versus only integers), which are
almost two different languages.


Moreover it seems mostly a performance improvement (did I miss
something?

Yes.


[...] I grew the
gut-feeling that a new Lua version would have had some enhancement
on the pattern matching side (lpeg or pattern improvements) or some
enhanced/added meta-mechanisms (new metamehods to enhance table
virtualization capability or some "macro-like" facility).

As I already said, this is not Lua 5.3.  This is a work version
specifically aimed at experimenting with this first implementation
of integers.

-- Roberto


Thanks very much for the thorough explanation!

-- Lorenzo

--
()  ascii ribbon campaign - against html e-mail
/\  www.asciiribbon.org   - against proprietary attachments