This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Don’t CLONE nameless hashes
authorFather Chrysostomos <sprout@cpan.org>
Tue, 23 Nov 2010 00:42:00 +0000 (16:42 -0800)
committerFather Chrysostomos <sprout@cpan.org>
Tue, 23 Nov 2010 00:43:32 +0000 (16:43 -0800)
commit605aedcce76632b4ab6d032b928335097c11784a
tree0a6f0fac2bf2083b91da89595f7d7bcf7fa2e0f7
parent0a4df5147978fdeecf143dcc58bc4e04e196aced
Don’t CLONE nameless hashes

The cloning code was trying to call CLONE on nameless hashes that nonetheless had an effective name (HvENAME).

This can happen if a nameless hash is assigned over a stash, as in

  *foo:: = {}

or if a stash is undefined:

  undef %foo::

(The effective name is how perl tracks the location internally, for
the sake of updating MRO caches.)
sv.c