Interestingly, the code: ... complains that you "Can't localize lexical variable @array", but it has no problem localizing $hash{foo}.
Because $hash{foo} is a scalar and it is localizing the value.
In reply to Re^5: use 'local' modifier to hashref element
by jakeease
in thread use 'local' modifier to hashref element
by schetchik
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |