Too golfy or arcane?
All of these map_pairs implementations are in the red zone of the arcanometer.
The interesting thing to note is that I seem to get a magical localization of my variables.
Array elements aren't lexical variables, if that's what you're talking about.
As for using local on array elements, perlsub says
Some types of lvalues can be localized as well : hash and array elements and slices, conditionals (provided that their result is always localizable), and symbolic references. As for simple variables, this creates new, dynamically scoped values.
That means
my @a; local $a[0]; # Not a problem my %a; local $a{k}; # Not a problem
In reply to Re^4: Mini-Tutorial: Working with Odd/Even Elements
by ikegami
in thread Mini-Tutorial: Working with Odd/Even Elements
by ikegami
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |