On Sun, Apr 11, 2010 at 2:17 PM, Dave Mitchell <davem@iabyn.com> wrote: > Anyway, I can see three possibilities for the behaviour of 'local @tied': > A fourth, or maybe zeroth, possibility would be for localizing a tied array to throw an exception. What happens with localizing slices of tied hashes? Or slices of arrays? local @ENV{qw/PATH USER/} = qw(/umkc/lib/garden hlinda); Making the operation on @arr equivalent to the operation on @arr[0..$#arr] makes sense, but that might be broken too ( i do not know ) calling STORE and FETCH on a tied array (or a tied hash slice) a lot seems wrong, as the side effects could be horrible. maybe local(@tied) could be disallowed under strict? maybe local could introduce a wrapper layer that would intercept accesses to the localized elements and refer them to in-memory data? local @ta; would use the non-tied option, and local $ta[4] would become something like $saved = \@ta; tie @{*ta = []}, Tie::Array::Overlay => $saved, 4Thread Next