summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFather Chrysostomos <sprout@cpan.org>2012-09-16 00:20:07 -0700
committerFather Chrysostomos <sprout@cpan.org>2012-09-17 16:57:51 -0700
commit62698e047b935ed44827dc9c8a013c1c41a9697d (patch)
tree41fae775ad95abb018cab74a91acbfcfba3a7aa4
parent441078c249a2505af353ca7b2f96789341d1b8eb (diff)
downloadperl-62698e047b935ed44827dc9c8a013c1c41a9697d.tar.gz
pp.c:pp_clonecv: Use find_runcv to find the padname
See: https://rt.perl.org/rt3/Ticket/Display.html?id=113930#txn-1153156 By using find_runcv, we can revert d2c8bf052f. This may not be the best tradeoff in the long run, as it makes code using experimental my subs (my experimental subs?) slower. But at least we avoid slowing down existing code.
-rw-r--r--pp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/pp.c b/pp.c
index e587f7d1c3..f99c460a8d 100644
--- a/pp.c
+++ b/pp.c
@@ -163,7 +163,8 @@ PP(pp_clonecv)
{
dVAR; dTARGET;
MAGIC * const mg =
- mg_find(AvARRAY(PL_comppad_name)[ARGTARG], PERL_MAGIC_proto);
+ mg_find(PadlistNAMESARRAY(CvPADLIST(find_runcv(NULL)))[ARGTARG],
+ PERL_MAGIC_proto);
assert(SvTYPE(TARG) == SVt_PVCV);
assert(mg);
assert(mg->mg_obj);