This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
op.c:pmruntime: Remove redundant cv_forget_slab
authorFather Chrysostomos <sprout@cpan.org>
Thu, 12 Jul 2012 19:06:29 +0000 (12:06 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Thu, 12 Jul 2012 20:20:10 +0000 (13:20 -0700)
This comes after newATTRSUB, which itself causes the CV to forget its
slab, except after a parse error, in which case the slab will be
cleaned up shortly anyway when the CV is freed.

op.c

diff --git a/op.c b/op.c
index e97a743..1ce69f1 100644 (file)
--- a/op.c
+++ b/op.c
@@ -4712,8 +4712,6 @@ Perl_pmruntime(pTHX_ OP *o, OP *expr, bool isreg, I32 floor)
                 * pad_fixup_inner_anons() can find it */
                (void)pad_add_anon(cv, o->op_type);
                SvREFCNT_inc_simple_void(cv);
-
-               cv_forget_slab(cv);
            }
            else {
                pm->op_code_list = expr;