in reply to Shared hash of anonymous arrays?
try removing the :shared attribute from the my %foo declaration.
(do you intend to share the entire hash %foo or only $foo{bar}?)
updated: i'm potentially way off base there, i am able to get it to 'work' (that is, stop producing the "Invalid value for shared scalar" error) using this approach or the others mentioned (@{$foo{'bar'}} = ($i, $j, $k);). it does seem plausible that you can't re-assign a new array-ref to a shared variable, but who knows what magic lurks beneath...? (not i!)
|
---|