Chris Dale writes:
: Does the alias operator, C<< -> >>, work for C<if> blocks too?
:       
:       if $a * $b / $c + $d -> $abcd { ... }
:       
: Where $abcd would be lexically scoped to the if block and else block,
: if defined.  I expect it could be used with any block statement,
: since Apoc 4 demonstrates it with for, grep, loop, and given.

I haven't decided whether it makes sense for C<if> or C<while> to try
to pass anything to their blocks.  We'd either have to hardwire it
syntactically to look for -> and do something different, which is icky,
or we'd have to make it assume -> $_ when there wasn't an arrow, which
is ickier.  People aren't going to expect $_ to get overridden like
that.

Larry

Reply via email to