lua-users home
lua-l archive

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


Hi,

Well, "not not x" might not get what you want any way.. say if you want 0 (zero) to be false,
or have a string-version converted to bool too. But it's really quite easy, so it's no big deal
and add it to your own code.

//Andreas

Vyacheslav Kalitkin wrote:
Hello,

I want suggest you to add "toboolean()" like existing tonumber() and tostring() functions. I know what "not not X" is same result, but looking toboolean(X) is more clear.

Best regards,
Vyacheslav Kalitkin