summaryrefslogtreecommitdiff
path: root/hv.h
diff options
context:
space:
mode:
authorTony Cook <tony@develop-help.com>2016-01-18 17:42:32 +1100
committerTony Cook <tony@develop-help.com>2016-02-08 14:52:51 +1100
commitac3b837b9e1b412c93837ea13eacd367439264ec (patch)
tree1a57c2a1b3721be0a9d9e9b2aae739f1c0ba29bc /hv.h
parent27895dda808516d2e00748a19f6648febae7161f (diff)
downloadperl-ac3b837b9e1b412c93837ea13eacd367439264ec.tar.gz
[perl #126410] keep the DESTROY cache in mro_meta
We're already keeping destroy_gen there, so keep the CV there too. The previous implementation, introduced in 8c34e50d, kept the destroy method cache in the stash's stash, which broke B's SvSTASH method. Before that, the DESTROY method was cached in overload magic. A previous version of this patch didn't clear the destructor cache on a clone, which caused ext/XS-APItest/t/clone_with_stack.t to fail.
Diffstat (limited to 'hv.h')
-rw-r--r--hv.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/hv.h b/hv.h
index e30f262f94..d7cc42f7d2 100644
--- a/hv.h
+++ b/hv.h
@@ -82,6 +82,7 @@ struct mro_meta {
const struct mro_alg *mro_which; /* which mro alg is in use? */
HV *isa; /* Everything this class @ISA */
HV *super; /* SUPER method cache */
+ CV *destroy; /* DESTROY method if destroy_gen non-zero */
U32 destroy_gen; /* Generation number of DESTROY cache */
};