And with the new refaliasing feature, as I understand it, that becomes:
use v5.22; use feature 'refaliasing'; no warnings 'experimental::refaliasing'; sub sum { \local our @a = shift; my $total = 0; $total += $a[ $_ ] for 0 .. $#a; return $total; }
In reply to Re^2: local our $var; What does it do?
by Anonymous Monk
in thread local our $var; What does it do?
by kcott
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |