Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Using clone/dclone with threads

by Anonymous Monk
on Nov 22, 2004 at 03:27 UTC ( #409471=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    {
        package cfg;
    ...
        %cfg::sessions = ();
        threads::shared::share(%cfg::sessions);
    }
    
  2. or download this
    $myhash{A} = $cfg::sessions{A};
    
  3. or download this
    use Storable qw(dclone);
    $myhash{A} = dclone($cfg::sessions{A});
    
  4. or download this
    use Clone qw(clone);
    $myhash{A} = clone($cfg::sessions{A});
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://409471]
Approved by ysth
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (5)
As of 2021-11-29 04:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?