Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^3: %+ and cloning

by JavaFan (Canon)
on Jan 11, 2010 at 12:40 UTC ( #816711=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub copy_hash {
        my $hr = shift // return {};
    ...
        @$copy{keys %$hr} = value %$hr;
        $copy;
    }
    
  2. or download this
    sub copy_hash {{%{$_[0]//{}}}}
    
  3. or download this
    my %copy = %+;
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://816711]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (11)
As of 2014-09-16 13:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (19 votes), past polls