lua-users home
lua-l archive

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


> I find that the reference manual for Lua 5.1 is disturbingly vague on 
> the matter of converting numbers to strings and strings to numbers.  
> Pretty much all it says is in section 2.2.1, string to number is done 
> "following the usual conversion rules", and number to string is done 
> "in a reasonable format".

We explicitly avoid too much restrictions here. If you want anything
specific when converting numbers to strings, you should use
string.format. If you want very specific syntax when converting strings
to numbers, use pattern matching.

-- Roberto