lua-users home
lua-l archive

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


> What precisely are we talking about?
> 
> (1)  1 + "2"  (- * / etc)
> 
> (2)  1 .. "2"
> 
> (3)  concat({1,"2"})
> 
> (4)  format("%s",1)
> 
> I suppose only in the first case automatic conversion is unwanted?
> Actually I can imagine that a future concat does a tostring if
> needed so that { 1, "2", true } also works.

I am talking mostly about (1). (2) could be kept, but probably
implemented through some metamethod by the standard library.
(3), (4), and others could be handled on an individual basis. (For
instance, does anyone need string.gsub(10000, 0, 1)?)

-- Roberto