lua-users home
lua-l archive

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


Use space character after number in such case:

> print(64 .. 'KB')
64KB
>

AFAIR this is mentioned in "Programming in Lua".

On Mon, Sep 17, 2012 at 3:32 PM, Egor Skriptunoff <egor.skriptunoff@gmail.com> wrote:
This string causes "malformed number" error:
print(64..'KB')
It seems that lexer does not know that two dots are never contained in
numerical constant.
IMHO, correct parsing of numerical constant should stop before
concatenation operator.




--
BR,
Michał Łowicki