[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua 5.3 work1 Considering math.isinteger or type()
- From: Petite Abeille <petite.abeille@...>
- Date: Thu, 25 Jul 2013 00:39:09 +0200
On Jul 17, 2013, at 10:10 AM, David Demelier <demelier.david@gmail.com> wrote:
> I just hope that one of these 2 solutions will be approved and added
> for the final Lua 5.3
What about neither?
Out of curiosity… as the 46 (and counting) messages in this thread haven't made it very clear, at least to me… why do we even care if a number is an integer, float, real, double, whatnot? Isn't the purpose of that int vs. float dichotomy to be purely an implementation detail? Wholly transparent? And a number stays a number? Irrespectively of internal representation? Or?
Joshua Jensen, all the way back on July 6, 2 bazillions messages ago, in reply to "[ANN] Lua 5.3.0 (work1) now available", said:
"I played around with this a bit. The only thing I found that appears to be missing is the ability to determine the actual type of the number. "
To which LHF replied:
"One shouldn't need to do this but you can do it as follows: … --[[ clever piece of Lua code here ]]--"