diff options
author | Father Chrysostomos <sprout@cpan.org> | 2012-11-25 13:03:07 -0800 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2012-11-25 17:12:41 -0800 |
commit | 0f534aaf12174a6c02f455475bef3141f46c221b (patch) | |
tree | eb8c93d2a2d148adb102dd40bbde57d04990eafc /t | |
parent | e759bc314f0fb0eebf211ca20ce3b52cbce6bd71 (diff) | |
download | perl-0f534aaf12174a6c02f455475bef3141f46c221b.tar.gz |
Stop cv-to-glob assignment redef warnings from leaking
We should not increment the reference count of the assignee until we
are past the warnings. It should only happen when the reference-
counted location is actually made to hold the assignee.
At the same time, I changed it to use a more specific variant of
SvREFCNT_inc, for speed.
Diffstat (limited to 't')
-rw-r--r-- | t/op/svleak.t | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/t/op/svleak.t b/t/op/svleak.t index e3f6be4e6b..a3c14b80b6 100644 --- a/t/op/svleak.t +++ b/t/op/svleak.t @@ -87,11 +87,11 @@ eleak(2, 0, "no warnings; use feature ':all'; $all my sub foo{} sub foo:lvalue{}", 'fatal mysub redef warning'); eleak(2, 0, "$all sub foo{} sub foo{}", 'fatal sub redef warning'); -$::TODO = 'still leaks'; eleak(2, 0, "$all *x=sub {}", 'fatal sub redef warning with sub-to-glob assignment'); eleak(2, 0, "$all *x=sub() {1}", 'fatal const sub redef warning with sub-to-glob assignment'); +$::TODO = 'still leaks'; eleak(2, 0, "$all XS::APItest::newCONSTSUB(\\%main::=>name=>0=>1)", 'newXS sub redefinition with fatal warnings'); eleak(2, 0, "$f 'misc'; my\$a,my\$a", 'double my with fatal warnings'); |