As a side note, it is interesting to see how List::Util deals with ($a,$b):
sub reduce (&@) { my $code = shift; return shift unless @_ > 1; my $caller = caller; local(*{$caller."::a"}) = \my $a; local(*{$caller."::b"}) = \my $b; $a = shift; foreach (@_) { $b = $_; $a = &{$code}(); } $a; }
In reply to Re: sort routines crossing package lines
by fglock
in thread sort routines crossing package lines
by DrWhy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |