diff options
author | David Mitchell <davem@iabyn.com> | 2018-04-26 11:46:22 +0100 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2018-04-26 11:46:22 +0100 |
commit | d8306453385a4991e40b4738982bf9617b6c1ccf (patch) | |
tree | f8083043183e2f3960a91d4f8eae78dec0735ddf /t/op | |
parent | d98f51adb895010fdfbe73640d0f92bb48669f24 (diff) | |
download | perl-d8306453385a4991e40b4738982bf9617b6c1ccf.tar.gz |
Revert "Strengthen weak refs when sorting in-place"
This reverts commit f6107ca24b4cf22dcf7fd69d65612ad718c48fca.
See RT #132142.
For now, re-introduce the bug that fails to convert weak refs to strong
refs when sorting in place.
This is commit 2 of 2.
Diffstat (limited to 't/op')
-rw-r--r-- | t/op/sort.t | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/t/op/sort.t b/t/op/sort.t index 610db691b8..d201f00afd 100644 --- a/t/op/sort.t +++ b/t/op/sort.t @@ -7,7 +7,7 @@ BEGIN { set_up_inc('../lib'); } use warnings; -plan(tests => 200); +plan(tests => 199); # these shouldn't hang { @@ -492,18 +492,7 @@ cmp_ok($x,'eq','123',q(optimized-away comparison block doesn't take any other ar @a = sort { $a <=> $b } @a; $$r = "z"; is ("@a", "3 4 5", "RT #128340"); -} -# in-place sorting of weak references -SKIP: { - skip_if_miniperl("no dynamic loading on miniperl, no extension Scalar::Util", 1); - require Scalar::Util; - my @a = map { \(my $dummy = $_) } qw(c a d b); - my $r = $a[1]; - Scalar::Util::weaken($a[1]); - @a = sort { $$a cmp $$b } @a; - undef $r; - ok defined $a[0] && ${$a[0]} eq 'a', "in-place sort strengthens weak references"; } # Test optimisations of reversed sorts. As we now guarantee stability by |