in reply to Re: %+ and cloning
in thread %+ and cloning
Thanks for your insight.
So I went back to twig technology and copied the hash viasub copy_hash { my $hr = shift // return {}; # get hash to copy or return empty ha +shref if not given my %copy = (); while (my ($k, $v) = each %{$hr}) { $copy{$k} = $v; } return \%copy; }
Which works. So this is it? Best way to go?
Bye
PetaMem All Perl: MT, NLP, NLU
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: %+ and cloning
by BrowserUk (Patriarch) on Jan 11, 2010 at 13:04 UTC | |
by JavaFan (Canon) on Jan 11, 2010 at 16:39 UTC | |
Re^3: %+ and cloning
by JavaFan (Canon) on Jan 11, 2010 at 12:40 UTC |
In Section
Seekers of Perl Wisdom