docs.scala-lang
docs.scala-lang copied to clipboard
if/then/else, for, and old syntax
Hi,
This page talks about control structures. For the if/then/else it only expose the (new ?) syntax
if a < b then
something
else
something_else
But for the for or the while construct, it also show the old syntax with parenthesis around the condition and curly brackets. Isn't it a bit confusing? Should not the doc either:
- present the old syntax for the if/then/else too
- or present only the new syntax for all construct (my preferred solution)?
present the old syntax for the if/then/else too
agree
I just looked at this bug and that page, and if I understand it right, I think this has been completed as part of #2481, and can be closed?
I think you're right.