develooper Front page | perl.perl5.porters | Postings from June 2020

Re: Dual-life perl 5-or-7 code and prototypes - impossible?

Thread Previous | Thread Next
From:
Tomasz Konojacki
Date:
June 29, 2020 17:49
Subject:
Re: Dual-life perl 5-or-7 code and prototypes - impossible?
Message ID:
20200629194906.4C56.5C4F47F8@xenu.pl
On Mon, 29 Jun 2020 18:33:46 +0100
"Paul \"LeoNerd\" Evans" <leonerd@leonerd.org.uk> wrote:

> On Mon, 29 Jun 2020 19:13:42 +0200
> Salvador Fandiño <sfandino@gmail.com> wrote:
> 
> > If you want to remain compatible with both perl5 and perl7, you are 
> > going to have the worst of both worlds. You would not be able to use 
> > "features" removed from perl7 neither would you be able to use the
> > new features added.
> 
> I'm not looking for my code to use new features of perl 7. I'm looking
> for it to install cleanly without breaking.
> 
> Right now it is impossible (outside of Sub::Attribute::Prototype or
> other hackery) to write a .pm file using prototypes which will work
> correctly on both perl 5 and perl 7.

To clarify: "perl 5" in this case means "perl 5.18 or below".

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