DIP1001: DoExpression
Cauterite via Digitalmars-d
digitalmars-d at puremagic.com
Sat Sep 3 09:38:17 PDT 2016
On Saturday, 3 September 2016 at 16:10:16 UTC, Jonathan M Davis
wrote:
> .. and from what I've seen, it seems to be the case that just
> about only the only folks who read it correctly are the ones
> who use it frequently ..
You know what else is easy to misread?
{
x;
y;
return z;
}();
Because until you reach the () at the end you have no idea
whether this is supposed to be an anonymous function to be called
elsewhere or a series of statements to be executed right now.
Sure, the comma expression isn't used very often, but when I do
need to use it I don't want to have to put garbage syntax like
that in my code. When you're reading code and you see `do(` you
know straight away what's going on.
More information about the Digitalmars-d
mailing list