jastrachan | 8 Jul 12:11 2004
Picon

Re: String/number conversion

On 8 Jul 2004, at 11:09, Aleksei Valikov wrote:
> Hi.
>
>>> I think it is quite natural that "1" - 1 = 0 and "1" + 1 = 2. 
>>> However, i would also expect a - 1 = 0 and a + 1 = 2 if a = "1". Do 
>>> we have any disagreement on that?
>> Personnaly, I disagree.
>> When I write:
>> println "4 + 1 = " + 5
>> I want "4 + 1 = 5" in return.
>> I don't want my String to be converted to an int.
>
> I think you're right. I was a bit mislead by "what's wrong with 
> javascript" FAQ entry.

I don't know who wrote that :)

James
-------
http://radio.weblogs.com/0112098/


Gmane