Mailing List Archive

issue #21044: mortalization of undef return
Porters,

This email is about a release blocker, #21044 <https://github.com/Perl/perl5/issues/21044>.

snowdrop:~$ perl5.36.0 -e '$_->{x} for sub { undef }->()'
snowdrop:~$ echo $?
0

Great. But:

snowdrop:~$ perl5.37.10 -e '$_->{x} for sub { undef }->()'
Modification of a read-only value attempted at -e line 1.

This affects code on the CPAN, and it doesn't seem like an extremely unusual thing to expect out in the world. Richard L. suggested we revert #20800 <https://github.com/Perl/perl5/pull/20800>. Any objections or better ideas?

--
rjbs
Re: issue #21044: mortalization of undef return [ In reply to ]
On Sat, May 06, 2023 at 10:25:04AM -0400, Ricardo Signes wrote:
> Porters,
>
> This email is about a release blocker, #21044 <https://github.com/Perl/perl5/issues/21044>.
>
> snowdrop:~$ perl5.36.0 -e '$_->{x} for sub { undef }->()'
> snowdrop:~$ echo $?
> 0
>
> Great. But:
>
> snowdrop:~$ perl5.37.10 -e '$_->{x} for sub { undef }->()'
> Modification of a read-only value attempted at -e line 1.
>
> This affects code on the CPAN, and it doesn't seem like an extremely unusual thing to expect out in the world. Richard L. suggested we revert #20800 <https://github.com/Perl/perl5/pull/20800>. Any objections or better ideas?

https://github.com/Perl/perl5/pull/21064

reverts c56d7fa91 aka #20800 while adding a test for the behaviour it broke.

Tony
Re: issue #21044: mortalization of undef return [ In reply to ]
This has been merged, thanks!

On Sat, May 6, 2023, at 11:33, Tony Cook wrote:
> On Sat, May 06, 2023 at 10:25:04AM -0400, Ricardo Signes wrote:
> > Porters,
> >
> > This email is about a release blocker, #21044 <https://github.com/Perl/perl5/issues/21044>.
> >
> > snowdrop:~$ perl5.36.0 -e '$_->{x} for sub { undef }->()'
> > snowdrop:~$ echo $?
> > 0
> >
> > Great. But:
> >
> > snowdrop:~$ perl5.37.10 -e '$_->{x} for sub { undef }->()'
> > Modification of a read-only value attempted at -e line 1.
> >
> > This affects code on the CPAN, and it doesn't seem like an extremely unusual thing to expect out in the world. Richard L. suggested we revert #20800 <https://github.com/Perl/perl5/pull/20800>. Any objections or better ideas?
>
> https://github.com/Perl/perl5/pull/21064
>
> reverts c56d7fa91 aka #20800 while adding a test for the behaviour it broke.
>
> Tony
>
>