lua-users home
lua-l archive

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

> Is there a reason why the coercion first recognizes the string as
> representing an int and then "throws away" that info and converts it
> unconditionally into a float?

We want a fast track for integers, so the first check is simply whether
both operands are integers. After that check, it is too cumbersome to
recheck whether the strings are "integers" and then also do an integer

-- Roberto