Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer

PetaMem's scratchpad

by PetaMem (Priest)
on Jun 01, 2004 at 19:03 UTC ( [id://358403] : scratchpad . print w/replies, xml ) Need Help??

use strict; use warnings; use Storable qw(dclone); use Data::Dumper; my $str = "Rico"; $str =~ m{(?<name>ico)}xms; my $match = dclone \%+; print Dumper($match); $str =~ m{(?<buba>R)}xms; my $match2 = dclone \%+; print Dumper($match); print Dumper($match2); # Why are $match and $match2 identical? I'd expect $match to keep its old value.