diff options
-rw-r--r-- | pp_hot.c | 7 | ||||
-rw-r--r-- | t/op/sub.t | 3 |
2 files changed, 0 insertions, 10 deletions
@@ -5085,13 +5085,6 @@ Perl_leave_adjust_stacks(pTHX_ SV **from_sp, SV **to_sp, U8 gimme, int pass) } } } - else if (SvIMMORTAL(sv)){ - /* Since SvIMMORTALs are never freed, even when their - * refcount drops to zero, there's no benefit in - * creating a mortal copy. - */ - *++to_sp = sv; - } else { /* Make a mortal copy of the SV. * The following code is the equivalent of sv_mortalcopy() diff --git a/t/op/sub.t b/t/op/sub.t index 0eae1d50de..e703880ec8 100644 --- a/t/op/sub.t +++ b/t/op/sub.t @@ -445,8 +445,5 @@ fresh_perl_like( ); # github #21044 -{ - local $TODO = "sub return values not modifiable"; ok( eval { $_->{x} = 1 for sub { undef }->(); 1 }, "check sub return values are modifiable") or diag $@; -} |