Front page | perl.perl5.porters |
Postings from July 2020
Re: Announcing Perl 7
Thread Previous
|
Thread Next
From:
Branislav Zahradník
Date:
July 4, 2020 03:26
Subject:
Re: Announcing Perl 7
Message ID:
CAB=rbOk6d-FC7t4zwL9ZJuyZWWkPJdC7Z+XCJ0A=V_iGRxieJg@mail.gmail.com
On Fri, 3 Jul 2020 at 20:30, Scott Baker <scott@perturb.org> wrote:
> I think this is a great solution. Certainly it's not sustainable to
> continue forever with:
> use v7
> use v8
> use v9
>
> As it's going to get crazy after a while.
>
In-source language version (or protocol version) is the greatest feature of
perl. It allows you to handle eventual consistency problems.
In languages you mentioned you can use only one version of language
specification - one which is supported by your tooling.
That will become quite an issue once you have a large code base. It may
force you to maintain code you already deprecated.
On other hand it can be easily handled automatically by scriptable
refactoring tools (PPI, Babble, Code::ART, whatever comes in future)
along with CI tools. And ability to specify future version of protocol just
to disable usage of constructs that will be deprecated in a short future?
IMHO Invaluable.
As far as I know no other language requires you to *opt in *to latest
> version like this. Certainly not the languages I play in: C, C++, Python,
> PHP, Javascript.
>
> I understand the use v7 thing because we have so much legacy code to
> support (for now). Over the course of the next X years/versions the amount
> of old and non-updated code will diminish and we could then assume the
> latest version unless we see a specificalyy use vX.
>
> I support use v7 if the goal is to eventually get that legacy code (CPAN,
> etc) upgraded to support new features so that future versions of the
> interpreter can assume the current version and emit warnings or
> deprecations on old syntax/features.
>
> I'm new to all of this so my vote means nothing, but I think this is a
> good goal. Use v7 for now, with the goal of "assuming current version" in
> the future when the code base catches up. The goal should be to make things
> easy for new developers. Right now there is a lot of tribal knowledge just
> to get started on "modern Perl".
>
> - Scott
> On 7/3/2020 10:47 AM, Paul "LeoNerd" Evans wrote:
>
> I'm saying that **right now** it should continue to behave like Perl 5,
> but after a suitable announcement period it should start giving
> "version is ambiguous" warnings. At some further point after that we
> can have it be an outright error for there not to be a version
> declaration, at which point we're free to cut off an older version of
> perl if we so wish.
>
> And by forcing everyone to have declared their version requirements by
> then we can do a simple grep for "use v5" across all of CPAN to gain a
> very easy simple metric on how much actual CPAN code is actually still
> using v5. When we feel that number is small enough - or the remaining
> outliers unimportant enough - we can cut it off.
>
>
Thread Previous
|
Thread Next