diff options
author | Brandon Black <blblack@gmail.com> | 2007-04-29 12:27:03 -0500 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-04-30 09:22:58 +0000 |
commit | dd69841bebe1fc7f7a6b248576221520a0418d52 (patch) | |
tree | 03f70519210b8c576d1dde888623afef3e9882ba /hv.c | |
parent | 49d7dfbcef7527d25e8c34643f831ef2416923a3 (diff) | |
download | perl-dd69841bebe1fc7f7a6b248576221520a0418d52.tar.gz |
Re: mro status, etc
From: "Brandon Black" <blblack@gmail.com>
Message-ID: <84621a60704291527y1b39be37l221ef66e4c828f66@mail.gmail.com>
p4raw-id: //depot/perl@31107
Diffstat (limited to 'hv.c')
-rw-r--r-- | hv.c | 9 |
1 files changed, 7 insertions, 2 deletions
@@ -1608,6 +1608,8 @@ Perl_hv_clear(pTHX_ HV *hv) HvREHASH_off(hv); reset: if (SvOOK(hv)) { + if(HvNAME_get(hv)) + mro_isa_changed_in(hv); HvEITER_set(hv, NULL); } } @@ -1756,7 +1758,6 @@ S_hfreeentries(pTHX_ HV *hv) if((meta = iter->xhv_mro_meta)) { if(meta->mro_linear_dfs) SvREFCNT_dec(meta->mro_linear_dfs); if(meta->mro_linear_c3) SvREFCNT_dec(meta->mro_linear_c3); - if(meta->mro_isarev) SvREFCNT_dec(meta->mro_isarev); if(meta->mro_nextmethod) SvREFCNT_dec(meta->mro_nextmethod); Safefree(meta); iter->xhv_mro_meta = NULL; @@ -1845,8 +1846,12 @@ Perl_hv_undef(pTHX_ HV *hv) return; DEBUG_A(Perl_hv_assert(aTHX_ hv)); xhv = (XPVHV*)SvANY(hv); + + if ((name = HvNAME_get(hv)) && !PL_dirty) + mro_isa_changed_in(hv); + hfreeentries(hv); - if ((name = HvNAME_get(hv))) { + if (name) { if(PL_stashcache) hv_delete(PL_stashcache, name, HvNAMELEN_get(hv), G_DISCARD); hv_name_set(hv, NULL, 0, 0); |