lua-users home
lua-l archive

Re: Coercion in concatenation.

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


2014年08月25日 9:06 GMT+02:00 Dirk Zoller <duz@sol-3.de>:
> But booleans?
> debug.setmetatable(false,{__concat=function(a,b) return tostring(a)..tostring(b) end})
> print("The test for (1==2) returns "..(1==2))
The test for (1==2) returns false

AltStyle によって変換されたページ (->オリジナル) /