On Wed, 30 Oct 2002, Michael Lazzaro wrote:
: On Wednesday, October 30, 2002, at 12:48 PM, Dave Storrs wrote:
: > for @a; @b -> $x is rw; $y { $x = $y[5] };
:
: I agree that it's an eyeful. How many of your issues could be solved
: if the above were just written:
:
: for (@a;@b) -> ($x is rw; $y) { $x = $y[5] };
:
: Would that suffice to make it clearer?
I think decent formatting would make it clearer:
for @a ; @b
-> $x is rw; $y {
$x = $y[5];
}
But just a single line break helps a lot:
for @a; @b
-> $x is rw; $y { $x = $y[5] };
But adding parens into a signature might actually make it incorrect,
depending on whether we go with [] or () for subsignatures. And putting
parens around (@a;@b) is likely to produce [@a],[@b], which would
bind to the signature wrong regardless of how it was written.
Larry