in reply to sharing array references through fork::shared

$queue[0] contains a reference to a reference to an anonymous array. This will illustrate:
my @queue; $queue[0] = \[1,2,3,4]; print "$queue[0]\n"; print "${$queue[0]}}\n"; print "@{${$queue[0]}}\n"; my $ref = ${$queue[0]}; print "$ref->[1]\n";
Gives:
REF(0x3a09c) ARRAY(0x3a1bc)} 1 2 3 4 2
Although, judging from the doc for threads::shared you might still have issues.

Replies are listed 'Best First'.
Re^2: sharing array references through fork::shared
by ajeet@perl (Acolyte) on Apr 11, 2010 at 09:33 UTC
    Thank you cdarke.... resolved my problem...also in thread::shared..