On Jan 24, 2011, at 1:18 PM, Jon Leighton wrote:

> Thanks for the explanation. FWIW I think it is a shame that postfix=20
> conditionals are semantically different to normal ones, but it's good =
to=20
> know why the difference occurs.

I think you are reversing cause and effect. The postfix condition
is not the source of the semantic surprise.

The surprise comes from the way Ruby disambiguates local variables
from argument-less method calls *at parse time*.  You can contrive
other examples of this surprise:

x rescue puts("x isn't a method here")
x =3D true
puts "x is now a local variable" if x
x rescue puts("this won't fail now because parser thinks x is a local =
variable")
x() rescue puts ("x still isn't a method")

Gary Wright=