develooper Front page | perl.perl5.porters | Postings from January 2022

Re: Things you can't do in a signatured sub

Thread Previous | Thread Next
From:
Paul "LeoNerd" Evans
Date:
January 24, 2022 14:55
Subject:
Re: Things you can't do in a signatured sub
Message ID:
20220124145450.4cc8cf4e@shy.leonerd.org.uk
On Fri, 21 Jan 2022 12:25:16 +0000
Dave Mitchell <davem@iabyn.com> wrote:

> So:
> for 5.36, add warning;
> for 5.38, remove @_ populating, and if we're lucky, stuff like
> aliasing will also be in 5.38 - otherwise we tell people to revert to
> non-signature subs for now for the hard stuff.
> 
> Personally I would still much prefer to add warnings and disable @_
> on the same release: that way there's not a release or two where
> people get warnings but everything still seems to work; so they add
> 'no warnings foo' and everything continues being fine, then all their
> code breaks a release later.

To this end, I have been working on a branch to print those warnings:

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

It sounds like we're in agreement on that part at least. Perhaps you
could give that one a review and at least we can get that part ticked
off.

-- 
Paul "LeoNerd" Evans

leonerd@leonerd.org.uk      |  https://metacpan.org/author/PEVANS
http://www.leonerd.org.uk/  |  https://www.tindie.com/stores/leonerd/

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About