lua-users home
lua-l archive

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


On Thu, Nov 28, 2019 at 1:28 PM Robert Virding wrote:
So in some case a string integer becomes a float:

> "123" + 1
124.0
> math.abs("123")
123.0

while in some other cases no conversion is done:

> math.max("123", -2.3, 1)
attempt to compare string with number



BTW, I've asked similar question about S2N-conversion anarchy in Lua
See question #5 in my post http://lua-users.org/lists/lua-l/2019-02/msg00049.html