Ary Borenszweig wrote:
> On 2/4/13 2:10 PM, "Jérôme M. Berger" wrote:
>> deadalnix wrote:
>>> 1/ Ruby.
>>>
>>> In Ruby, method are called without (). This is not ambiguous as
>>> fields are always private.
>>>
>> Note that in Ruby, this line:
>>
>> foo(1, 2)
>>
>> Means something different than:
>>
>> foo (1, 2)
>>
>> That may not be ambiguous for the computer, but it sure is for the
>> programmer....
>>
> irb(main):001:0> foo (1, 2)
> SyntaxError: (irb):1: syntax error, unexpected ',', expecting ')'
> foo (1, 2)
> ^
>
> Not ambiguous at all, it's a syntax error because (a, b) is not a valid
> expression.
>
Like I said, it is not ambiguous for the computer, but it is for
the developper.
Jerome
--
mailto:[email protected]
http://jeberger.free.fr
Jabber: [email protected]
signature.asc
Description: OpenPGP digital signature
