nddrylliog/nagaqueen — pull request #12 by shamanas (2012-06-24 23:15:45+00:00)
Title: Added parenthesis-free if and while

This has some subtleties.
The expression used as a conditional is the same as is allowed with the match expression.
This means that they must be simple values to work without parenthesis. No field access, no operators.
Why? Because, we are allowed to ignore the brackets of the body.
These are some scenarios where this is reflected:

if true toString() println() // Equivalent to if true { toString() println() }
while true toString() == "true" // Equivalent to while true { toString() == "true" }

This should be written down in some doc. Of course parenthesis can be used so this change is non-breaking.