Forum: Ruby Re: Ruby Whitespace Semantics

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
8ecb8bb62c3283f8069a54056c7dc25f?d=identicon&s=25 Jim Freeze (Guest)
on 2006-02-27 16:07
(Received via mailing list)
Matz has said that

a = (4
       +5)

will be supported in 1.9.
912c61d9da47754de7039f4271334a9f?d=identicon&s=25 unknown (Guest)
on 2006-02-27 17:54
(Received via mailing list)
Quoting Jim Freeze <jim@freeze.org>:

> Matz has said that
>
> a = (4
>        +5)

Hmm.  What about

 a = ( 4 ; + 5 )

?

I won't be heartbroken if it isn't, but I'm just wondering about the
implications for the grammar...

-mental
48641c4be1fbe167929fb16c9fd94990?d=identicon&s=25 Mark Wilden (Guest)
on 2006-02-27 20:04
(Received via mailing list)
<mental@rydia.net> wrote in message
news:1141059171.44032e636f879@www.rydia.net...

>Hmm.  What about
> a = ( 4 ; + 5 )

It should be a syntax error.
E34b5cae57e0dd170114dba444e37852?d=identicon&s=25 Logan Capaldo (Guest)
on 2006-02-27 20:10
(Received via mailing list)
On Feb 27, 2006, at 2:03 PM, Mark Wilden wrote:

> <mental@rydia.net> wrote in message
> news:1141059171.44032e636f879@www.rydia.net...
>
>> Hmm.  What about
>> a = ( 4 ; + 5 )
>
> It should be a syntax error.

Why? The semantics seem perfectly clear.
912c61d9da47754de7039f4271334a9f?d=identicon&s=25 unknown (Guest)
on 2006-02-27 20:50
(Received via mailing list)
Quoting Mark Wilden <mark@mwilden.com>:

> >Hmm.  What about
> > a = ( 4 ; + 5 )
>
> It should be a syntax error.

Ruby has an unary +...

-mental
C1bcb559f87f356698cfad9f6d630235?d=identicon&s=25 Hal Fulton (Guest)
on 2006-02-28 01:30
(Received via mailing list)
Mark Wilden wrote:
> <mental@rydia.net> wrote in message
> news:1141059171.44032e636f879@www.rydia.net...
>
>
>>Hmm.  What about
>>a = ( 4 ; + 5 )
>
>
> It should be a syntax error.

Why/how?


Hal
This topic is locked and can not be replied to.