On 3/16/06, Joel VanderWerf <vjoel / path.berkeley.edu> wrote:
> Zev Blut wrote:
>
> > In my fantasy Ruby these keyword logical operators would not exist or
> > they would be the same precedence.
>
> But consider the difference:
>
> x = h && h[4]
> x = h and h[4]
>
> x = gets and x.display
> x = gets && x.display
>
> It's really nice having both an operator ("&&") and a control structure
> ("and") that behave the way you want them to (as in the first line of
> each pair).
>

Maybe we just need to rename 'and' to 'and_then' or 'also', then.