|
|
Subscribe / Log in / New account

What happened to Perl 7?

The Perl Steering Council has posted a blog entry on its plans for the language and when Perl 7 might be released.

For now, our plan is to continue introducing new features and to resolve all existing experimental features, so they're either dropped, or become non-experimental features (and so are included in the version bundle). The downside with this is that people often can't remember which version of Perl introduced which feature(s). At some point in the future, the PSC may decide that the set of features, taken together, represent a big enough step forward to justify a new baseline for Perl. If that happens, then the version will be bumped to 7.0.


to post comments

What happened to Perl 7?

Posted May 26, 2022 15:48 UTC (Thu) by nas (subscriber, #17) [Link] (12 responses)

This "use feature" idea sounds great as a user. If I was implementing Perl, it sounds like a absolute nightmare. Perhaps they will find a way to make it work but I expect the Perl implementation will collapse under the weight of backwards compatibility logic if they never sunset any of those features.

What happened to Perl 7?

Posted May 26, 2022 16:52 UTC (Thu) by flussence (guest, #85566) [Link] (10 responses)

What are you talking about? "use feature" was introduced in 5.10, fifteen years ago.

What happened to Perl 7?

Posted May 26, 2022 17:38 UTC (Thu) by Smon (guest, #104795) [Link] (6 responses)

To quote the article:

> The downside with this is that people often can't remember which version of Perl introduced which feature(s).

What happened to Perl 7?

Posted May 26, 2022 19:37 UTC (Thu) by flussence (guest, #85566) [Link] (3 responses)

Unless RHEL's mispackaging of perl is even worse than its reputation suggests, there's a full list of them annotated with when they first appeared in `perldoc feature`.

What happened to Perl 7?

Posted May 26, 2022 19:58 UTC (Thu) by tialaramex (subscriber, #21167) [Link] (2 responses)

There's a full list of the United States on a decent map, there's a full list of Kings (and Queens) of England in history books, nevertheless people frequently can't name all fifty states, let alone all the Kings and Queens.

"There's a list" is an answer to "How do I know?" but not to "I can't remember".

What happened to Perl 7?

Posted May 26, 2022 21:07 UTC (Thu) by ballombe (subscriber, #9523) [Link]

Alternatively, it can be argued that it is much easier to guess version numbers that feature code name spelling.

What happened to Perl 7?

Posted May 26, 2022 22:12 UTC (Thu) by flussence (guest, #85566) [Link]

This is a weird tangent to go off on but at this point I've been sufficiently nerd sniped...

Nobody asks for or is impressed by rote memorisation of trivia like this, except high school exams and whiteboard interviewers at toxic workplaces; getting annoyed at the presumption of having to do so is silly when *you don't*! If you're using a programming language then you have a computer available, here's how to get a history of syntax-affecting feature flags straight out of the computer, ergo there's nothing wrong with it. (I wish pydoc was half as thorough...)

As an aside everyone in the vicinity now knows that 1) there's a self-contained CLI doc system 2) it contains useful information that you're not expected to memorise 3) the existence of said info implies perl doesn't do Flag Days with unavoidable breaking syntax changes.

Maybe the article could've spelled everything out and saved all this, but it's honestly asking too much to expect it to - it's aimed at entrenched perl5 users waiting for rapture after the broken mugs incident, who care about the specifics of things like the forward compatibility of postfix dereferencing sigils, and they all presumably got taught how to use their tools in the far less polite environment of the 90s/00s.

What happened to Perl 7?

Posted May 27, 2022 2:14 UTC (Fri) by jengelh (guest, #33263) [Link] (1 responses)

I would approach this by adding "use 5.26;" (whatever version the user had on their system) to the top first. If and when the user finds the willpower to validate/research that the program works with earlier/other versions, the number can be lowered, or be switched to "use feature".

What happened to Perl 7?

Posted May 29, 2022 23:47 UTC (Sun) by rra (subscriber, #99804) [Link]

I've been doing this for years, and it works fine. When a new release of Perl comes out, I read the release notes and see if any nice new features were introduced that might warrant updating the oldest supported Perl version in one or more of my modules.

Personally, I prefer use <version> to explicit use feature anyway since for documentation purposes the minimum supported version is the actually important information. (But I also don't tend to use any experimental features that are off by default.)

What happened to Perl 7?

Posted May 26, 2022 19:55 UTC (Thu) by tialaramex (subscriber, #21167) [Link] (1 responses)

It may be that, in at least most cases, in effect this is doing the same thing as Rust under the hood. There's not really a vast number of distinct Perl syntaxes modified by different combinations of use feature flags, instead there's a single syntax but if you don't use any particular feature flags parts of it are isolated from you and can't be used. They still exist, but you can't get at them.

This means that most of Perl's codebase needn't even be aware of feature flags, only the parsing logic. In the rest of the codebase it's as if all feature flags were always enabled.

What happened to Perl 7?

Posted May 27, 2022 0:13 UTC (Fri) by NYKevin (subscriber, #129325) [Link]

This is great, right up until you need to change the runtime semantics of something, a la Python 3 and Unicode.

At which point, I suppose, the answer is "Just don't do that then." Instead, you introduce a new object that exists at runtime, and the parsing logic creates either an instance of the new object or an instance of the old object depending on which feature flag is lexically in-scope for that particular declaration. Then new code gets new semantics, and old code gets old semantics. Problems:

* If the object is first-class, then old code will expect instances of the old type, and new code will expect instances of the new type, so you probably have to expose this difference in the type system.
* If the object instances can interact with each other, now you have to figure out the semantics of this interaction for each possible combination of versions.
* If the language supports generics and the object is first-class, can a generic class from the old version match (be instantiated with) the type of the new version?
* If the language is dynamically typed, good luck getting any of this right.

What happened to Perl 7?

Posted May 26, 2022 21:24 UTC (Thu) by nas (subscriber, #17) [Link]

The list of available features is still quite short, so it is probably not yet much of a burden in terms of maintenance. Are you claiming it's not going to be a maintenance burden once the set of available features gets large?

What happened to Perl 7?

Posted May 26, 2022 17:13 UTC (Thu) by RobertX (guest, #138591) [Link]

Perl, just like every other language, has the notion of deprecation and removal.

What happened to Perl 6?

Posted May 26, 2022 20:06 UTC (Thu) by meuh (guest, #22042) [Link] (10 responses)

No mention of Perl 6 ...

What happened to Perl 6?

Posted May 26, 2022 20:25 UTC (Thu) by rahulsundaram (subscriber, #21946) [Link]

That was already covered a couple of years back

https://lwn.net/Articles/802329/

What happened to Perl 6?

Posted May 26, 2022 22:10 UTC (Thu) by rgmoore (✭ supporter ✭, #75) [Link] (7 responses)

The people developing Perl 6 eventually decided it was too different from Perl 5 to be considered the next version and decided to rename it Raku instead. To avoid confusion, the people who continued to develop Perl 5 have decided to skip straight to Perl 7 if they ever want to increment the version number.

What happened to Perl 6?

Posted May 26, 2022 23:34 UTC (Thu) by pebolle (guest, #35204) [Link] (5 responses)

> The people developing Perl 6 eventually decided it was too different from Perl 5 to be considered the next version and decided to rename it Raku instead.

Is it too cynic to think that in the entire Perl 6 train wreck that is one of the few sensible decisions?

What happened to Perl 6?

Posted May 27, 2022 1:29 UTC (Fri) by felixfix (subscriber, #242) [Link] (4 responses)

Nope, I'm with you on that. It started with the best of intentions and went off the rails, as most good intentions do when bureaucracies dream them up.

What happened to Perl 6?

Posted May 30, 2022 16:45 UTC (Mon) by rgmoore (✭ supporter ✭, #75) [Link] (3 responses)

Perl 6/Raku wasn't invented by a bureaucracy, though; it was straight from the mind of Larry Wall. The big problem was second system effect. Perl had worked hard to maintain backward compatibility through Perl 5, which constrained Larry's ability to make big, incompatible changes. He threw that all out the window for the design of Perl 6/Raku, though, and just went wild with all the ideas he hadn't been able to follow through on for the previous 20 years. Some of those were good ideas- I think the extension of regexes to grammars and changing the way sigils work were long overdue- but many of them were just change for change's sake.

What happened to Perl 6?

Posted May 31, 2022 23:07 UTC (Tue) by bartoc (guest, #124262) [Link]

Not to mention it's whole runtime and meta-object system is somewhat .... idealized.

It does mean perl6 is almost self-hosting, which is neat I guess.

What happened to Perl 6?

Posted Jun 8, 2022 10:12 UTC (Wed) by niner (subscriber, #26151) [Link] (1 responses)

I have looked at a lot of features in Raku with a skeptical eye, but honestly, I still cannot point out anything that was clearly just done for change's sake. Not after understanding how those things actually fit together. Part of learning the language is having these moments of "oh, now that other thing makes sense". It's usually about consistency.

What happened to Perl 6?

Posted Jun 13, 2022 21:35 UTC (Mon) by flussence (guest, #85566) [Link]

There was brief loud pushback about “adding unnecessary complexity to the compiler” or whatever when − [U+2212] and friends (×÷) were added. But the little details like that make it so much nicer to use than, well, anything, that I rarely need to think twice about using `raku -e` for quick experiments. The only text-munging tool I use it can't reasonably replace is jq, and I can't use that without getting lost in its manpage for an hour…

What happened to Perl 6?

Posted May 27, 2022 6:09 UTC (Fri) by bof (subscriber, #110741) [Link]

Oh that's totally funny, in that it mirrors PHP history on the numbers - the difference being that PHP 6 from what I gather, never actually saw the light of day. Hilarious anyway.

What happened to Perl 6?

Posted May 28, 2022 3:14 UTC (Sat) by jahigd02 (guest, #158771) [Link]

Perl 6 became 'Raku' when it was decided that its changes were too different to warrant still calling it a 'Perl' version. Evidently, Perl 7 is going to be what 'Perl 6' would've been had it not been so radically different. Basically Perl5++.

What happened to Perl 7?

Posted May 26, 2022 23:27 UTC (Thu) by pebolle (guest, #35204) [Link]

So Perl 7 petered out.

But at least they made clear Perl 5/7 will stick to backward compatibility. It could have been much worse...

What happened to Perl 7?

Posted May 27, 2022 9:23 UTC (Fri) by Gladrim (subscriber, #45751) [Link] (22 responses)

"We want to drive the language forwards, increasing the rate at which new features are introduced"

That's pretty much the opposite of what I look for in a programming language.

I want stable. I want my programs to run unchanged in 10 or 20 years time. Sure, *bugs* need fixing, but programs shouldn't need updating because the language has changed underneath them. That kind of breakage is what frameworks are for.

What happened to Perl 7?

Posted May 27, 2022 10:12 UTC (Fri) by jorgegv (subscriber, #60484) [Link]

Absolutely +10!!

What happened to Perl 7?

Posted May 27, 2022 12:31 UTC (Fri) by rahulsundaram (subscriber, #21946) [Link] (17 responses)

> I want stable. I want my programs to run unchanged in 10 or 20 years time. Sure, *bugs* need fixing, but programs shouldn't need updating because the language has changed underneath them.

There is nothing at all wrong with accelerating the rate of change as long as backward compatibility is maintained and Perl developers have a good track record of doing so. I don't see the problem.

What happened to Perl 7?

Posted May 27, 2022 13:04 UTC (Fri) by Gladrim (subscriber, #45751) [Link] (16 responses)

Why does a mature programming language (>30 years in this case) need to be rapidly adding new features? I'd dubious that this should be a goal, or that it is compatible with being a stable, usable language.

What happened to Perl 7?

Posted May 27, 2022 15:03 UTC (Fri) by rahulsundaram (subscriber, #21946) [Link] (3 responses)

> Why does a mature programming language (>30 years in this case) need to be rapidly adding new features?

Other languages including C++ and Python are adding new features all the time despite being decades old. This is hardly unusual.

What happened to Perl 7?

Posted May 27, 2022 16:39 UTC (Fri) by Gladrim (subscriber, #45751) [Link] (2 responses)

Unusual? Sadly not. Car accidents aren't unusual either. Doesn't mean they're a good idea or something we should aspire to involve ourselves in.

What happened to Perl 7?

Posted May 27, 2022 20:30 UTC (Fri) by rahulsundaram (subscriber, #21946) [Link] (1 responses)

> Unusual? Sadly not. Car accidents aren't unusual either.

This is a bogus comparison. Car accidental are strictly harmful. Language changes can introduce substantial new widely anticipated features that are objectively an improvement to developers (I can point to any number of relatively recent C++ changes as examples here) although not universally so. If you have a preference for a more static language, just stick to an older version or continue using a language that barely changes at all, Perl may not be suitable for you. As long as backward compatibility is maintained, I still don't see a problem.

What happened to Perl 7?

Posted May 27, 2022 21:07 UTC (Fri) by Gladrim (subscriber, #45751) [Link]

It was a simple illustration that just because something is "hardly unusual" doesn't mean it's a good thing.

> If you have a preference for a more static language, just stick to an older version or continue using a language that barely changes at all, Perl may not be suitable for you.

Precisely. I think that was clear from my first comment.

What happened to Perl 7?

Posted May 27, 2022 16:33 UTC (Fri) by tialaramex (subscriber, #21167) [Link] (11 responses)

Turns out we learn stuff over time, in thirty years you can learn a lot. And as a result you may wish to introduce features reflecting what you learned. If the language insists on conservatism then the language as a whole reaps no benefit from what you learned, each individual programmer must cherish the lessons and maybe hope to pass them on, but the language doesn't help at all.

There's a lot of room between stuff that's hot this week but nobody will care about a year from now [which I agree Perl has no need for], versus stuff that if you still don't have it ten years from now people will laugh at grandpa's language for old-timey computers. I don't think the people writing this essay expect to ship a new Perl feature every week, but on the other hand it gets old fast when you're teaching newcomers your language but have to caution them that the feature you added *last* year still won't really be usable *next* year because the ecosystem is so slow to adopt change, so here's a nasty hack instead.

What happened to Perl 7?

Posted May 27, 2022 16:47 UTC (Fri) by Gladrim (subscriber, #45751) [Link] (10 responses)

Perl has evolved over thirty years, sure. So has C. Neither have evolved particularly rapidly, which is something I like about them. Perl6 aside, perl has been reasonably stable. I don't think speeding up the rate of change of a language is a worthwhile goal. Quite the opposite. There are plenty of fast-moving languages where this morning's code is this afternoon's bitrot. And whole new languages to try with different features for those that need or want to try them.

What happened to Perl 7?

Posted May 27, 2022 18:58 UTC (Fri) by NYKevin (subscriber, #129325) [Link] (7 responses)

> languages where this morning's code is this afternoon's bitrot

The baseline assumption of this discussion is that we don't break backwards compatibility. If you insist on postulating that all new features break backwards compatibility, then yeah, you're going to come to the conclusion that new features are bad.

That conclusion is wrong, though.

What happened to Perl 7?

Posted May 27, 2022 19:25 UTC (Fri) by Gladrim (subscriber, #45751) [Link] (6 responses)

No, my original comment was simply stating that I don't view faster moving as a benefit. It's not what I look for in a language. Quite the opposite. That was all.

Did I insist on postulating that all new features break ... anything? I don't think so.

Is there an increased risk of breakage if the rate of change increases? Yes. Of course.

Do I think it's where a mature, stable language should be focusing its energy? No.

YMMV

What happened to Perl 7?

Posted May 27, 2022 23:36 UTC (Fri) by tialaramex (subscriber, #21167) [Link]

> Is there an increased risk of breakage if the rate of change increases? Yes. Of course.

Maybe that's less obvious than you think it is. Once we accept that change is inevitable (which you seem to) then there's actually some reason to think we should prefer a somewhat steady tempo of change, not necessarily the minimum possible delta.

One reason is rust. Not the language, the problem. If you don't exercise freedom of motion it rusts into place without you realising. This is why TLS 1.3 is spelled SSL 0x0303 on the wire, first TLS needed to pretend to just be SSL 3 (hence TLS 1.0 was SSL 3.1, TLS 1.2 wsa SSL 3.3 aka 0x0303) and then even that rusted into place so TLS 1.3 pretends to be TLS 1.2 or else it won't work. So long as Perl ships new versions with new syntactical features every year or two, the propensity for things to rust into place can be curtailed, but imagine if Perl today and Perl from 2008 had the exact same syntax, by now some software would expect and require that syntax. New Perl would find that introducing features, even much needed and long awaited features, tripped this rusted into place hazard despite the supposed promise to be able to exercise this option. Ouch. You may have experienced something similar with muscle tone if you had "stay at home" restrictions during the pandemic.

Also, a steady pace of change means that tooling and culture adapts properly. If the last substantive change to Perl syntax had been in 2008, what's the chance automated testing catches syntax errors related to a new change made tomorrow? Approximately zero. But if such changes happen about every 18 months on average there's a good chance somebody actually wrote a test by now. Likewise if the last change was 2008 people who expect to be warned might not realise they weren't tracking this any more. People forget how the process works. If there are on average two features proposed every year, experienced users know how to read a proposed change, where to debate it, stuff like that. The community is prepared for, and equipped to handle change, because it's just routine.

What happened to Perl 7?

Posted May 29, 2022 23:57 UTC (Sun) by rra (subscriber, #99804) [Link]

You seem extremely upset over a possible problem that you have identified based on a small portion of a blog post and essentially no other confirming information. Maybe consider that you might be overreacting to a phrasing that happened to hit a sore point for you?

Perl has been exceptional at backward compatibility for many years. I have code I wrote in 1999 that is still running with no changes whatsoever. Given that, I'm happy to extend the benefit of the doubt and assume that this work will be done with the usual amount of care and deliberation, and I'm happy that they're working their way through the backlog of experimental features that were added to the language and then never resolved one way or the other.

What happened to Perl 7?

Posted May 29, 2022 23:58 UTC (Sun) by NYKevin (subscriber, #129325) [Link] (3 responses)

(puts SRE hat on)

Look, I've been there. I know that changes cause breakage, and I know that you can stop things from breaking if you stop making changes. The problem is, that's a short-term solution at best. For a few weeks or months, this can be highly effective:

* You had a bad week, you're all out of error budget, and you need some time to recover your SLO.
* Your company is having a big presentation or other event, and it would be really embarrassing to have an outage right at this moment.
* It's the holidays, and you really don't want to be stuck troubleshooting a production issue from your parents' house, while your great-but-technologically-illiterate uncle is trying to sell some cryptocurrency scam to your second cousin downstairs, when you would otherwise be able to prevent that transaction from taking place.

The problem is that this is not sustainable in the long run. You can't just freeze prod forever. The world is going to move on, with or without you. Eventually, you will need to change prod, and if it's been frozen for the past three years, then you are basically screwed, because you'll have to completely rebuild and redeploy absolutely everything, and make a massive change all at once. Some software won't exist anymore. Some software will exist, but will no longer be meaningfully maintained. Every piece of your technology stack is moving at a different speed, and you'll have to redo all of your version mix-and-matching from scratch. This is much, much riskier than smaller, incremental changes on a more frequent basis.

A language that barely changes is not a good thing. It's a liability. Eventually, developers will tire of working in that language, because it is missing features relative to other languages, and some of them will stop maintaining libraries and other stuff that you (probably unknowingly) depend on. Or they will get old and die/retire, and nobody will be interested in picking up the work, so it will go unmaintained by default. It's the https://xkcd.com/2347/ problem, but on a language-wide scale.

What happened to Perl 7?

Posted May 30, 2022 14:24 UTC (Mon) by tialaramex (subscriber, #21167) [Link] (2 responses)

For the holidays one, I'd really like companies who insist they can't change anything during the holidays to understand that this means they need to bring changes forward, to before the holiday.

One of the problems we repeatedly had in the Web PKI is that institutions will agree that "End of next year" is an acceptable last cut off, but then as December Y+1 approaches, they suddenly remember that they've got a "No changes during the holidays" policy - once their employees sign off before Thanksgiving (or similar) they won't make any changes until after New Year - and so, now they want the thing they agreed for December pushed back to February. Nope, if you really can't make changes during the holidays, when you agreed "End of next year" you needed to schedule in work before the holidays to hit that deadline. That's how time works. You aren't being "pragmatic" or showing "foresight" you are in fact incompetent because you are going to fail and then redefine it as success.

However, some of this stuff is getting easier as our industry matures. Examples: There probably won't ever be another encoding for the character 'A' having settled upon 65. If your code written in 1985 chose ASCII 'A' of 65 it's still fine today in an environment where UTF-8 'A' is deliberately also 65, while some of the other 1960s encodings did not agree. There's a good chance you'll never need a different symmetric encryption algorithm, AES is fine for conceivable problems. It looks like we're agreed that the octet is a byte and too bad if that's inconvenient. Even some ideas in programming are probably here to stay. As a result, although I agree change is constant and it's something Perl is wise to embrace as necessary and good, we shouldn't expect more seismic changes, often or perhaps ever. If Perl 7 ever does happen, I expect it will be less different from today's Perl than that Perl is from Perl 4 despite the big number.

What happened to Perl 7?

Posted May 30, 2022 16:21 UTC (Mon) by NYKevin (subscriber, #129325) [Link]

Always read and understand the fine print. If the fine print says that the year ends in February, then unfortunately, that means the year ends in February (for the purposes of that agreement). If the fine print doesn't say any such thing, then sure, hold them to their promises. Not pushing things during holidays is obviously a foreseeable event and they should plan for that. But it's possible that they "planned" for it by sticking a clause in the contract to allow for a delay, rather than by actually doing the work on-time like a sensible company.

What happened to Perl 7?

Posted May 31, 2022 23:12 UTC (Tue) by bartoc (guest, #124262) [Link]

You say that about encodings being stable (and they are for latin alphabetic characters) but there's a few characters in the 7-bit ascii set with a different encoding under GB18030, which is an encoding we'll probably have to care about for a long time, at least a little bit. That said UTF-8 is objectively better so I suspect the Chinese will slowly start to sunset 18030.

What happened to Perl 7?

Posted May 28, 2022 2:58 UTC (Sat) by rsidd (subscriber, #2582) [Link] (1 responses)

Also, perl dominated in the 1990s. Those new languages took away a lot of its mindshare because they had features programmers actually liked.

Python continues to dominate despite all the whining about python 3, because it is a good language that continues to add new features (eg, recently, pattern matching which is something I sorely missed from ML-type languages like ocaml). A bit longer ago, python 2 added list comprehensions (borrowing from haskell) which I personally use all the time, far more expressive (to my eyes) and more concise than map+filter. Who wants to use python 1 today?

What happened to Perl 7?

Posted May 31, 2022 9:16 UTC (Tue) by anton (subscriber, #25547) [Link]

I was puzzled by what you wrote, but I think you meant: "Pattern matching is something from ML that you sorely missed in (earlier) Python."

What happened to Perl 7?

Posted May 30, 2022 15:11 UTC (Mon) by jafd (subscriber, #129642) [Link] (2 responses)

I’d also like some performance improvements on top of what you said.

What happened to Perl 7?

Posted May 30, 2022 16:25 UTC (Mon) by pebolle (guest, #35204) [Link] (1 responses)

I would go for a pony!

What happened to Perl 7?

Posted Jun 2, 2022 1:52 UTC (Thu) by NYKevin (subscriber, #129325) [Link]

That's easy, just pass O_PONIES to open(2).


Copyright © 2022, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds