by joosters · 8y ago · 0 comments
This is a vastly larger change than python 2->3, and people are still using python 2.x. In short, there’s no sensible upgrade path, Perl 5 & 6 are very much their own language.
If Perl 6 wanted backwards compatibility, they needed to have thought about it a long time ago. Trying to hack in some Perl 5 style functions into it now seems futile...
Meanwhile the shiny new revolutionary Perl 6 took forever to release and when it finally did nobody cared anymore. Quoting Wikipedia:
>The design process for Perl 6 began in 2000. [...] on December 25, 2015, the first stable version of the specification was announced.
I can respect taking the time to do things right but when your development history resembles that of Duke Nukem Forever something is off. That in my opinion hurt Perl more than anything else, even more so than the lack of compatibility between Perl 5 and Perl 6. If Perl 6 had released in early-to-mid 2000 I think there would've been enough interest out there to bridge the gap. It would've been messy but it could've worked.
Instead Perl 5 felt a bit like a legacy language "while we wait for Perl 6 to be finished" and Perl 6 was nowhere to be found. And Perl went from the de-facto scripting language for un*x to people asking "Is Rakudo Perl 6 used in production?".
What I've heard about Perl 6 does sound intriguing, and probably a solid language platform does take a good decade-plus to get on solid footing. But re-using the name of a once-well-loved and established language is a bad move for both the old and the new versions.
Do you have a reference on changes to data structure syntax in 5.x? Probably my biggest frustration was trying to use anything beyond a scalar list - it always ended up a mess of hashrefs.
Larry said something similar on day one.
> and let the old project live out its own lifecycle.
Larry did exactly that. It's still living out its own lifecycle and will for another N decades.
> re-using the name of a once-well-loved and established language is a bad move for both the old and the new versions.
I agree that this has likely turned out to be the case for Perl 6.
As a Perl 5 developer, I look at it and go "If I have to learn a new language I might as well make it a popular one like Python 3 or Rust."
Of course, there are also reasons to learn a programming language beyond job listings; GP might work on things that don't require a specific language, be looking for a language for dude projects, or just want to learn a language for fun.
YMMV but for me this is what makes it easy to maintain: you just need to learn Python not the personal programming style of the previous developer.
Being "forced to use Python" sucks as a Perl developer.
sigh
(And for the record, I’ve dealt with 100K+ sloc perl and python projects, and the perl one was more maintainable than the python projects, even after multiple python rewrites. It doesn’t have to go that way, but it certainly can!)
I mean it only as a half joke, unfortunately.
If you want that regex behaviour in a more modern language than Perl5 then Ruby is there.
Perl 5 has a feeling of being 'complete' as a language. I guess this makes it unsexy and it'll never be the cutting edge where all the cool devs want to work, but it's rock solid stable and reliable.
Now, if only Perl 5 could get a JIT compiler...
Perl 5 running as a slang on MoarVM or JVM would give it a JIT compiler
Nah, what makes it unsexy is the Perl syntax. The world has moved on. The readability of modern languages like Python is on another level.
Are you aware of the compatibility with Perl 5 that I mentioned in my prior comment in this thread? If so, why do you discount it?
Three of the four are at the first stage. They work in much the same way, using `.run( ... )` to run a line of code at a time.
One of the four is at the second stage. It works as easily as using a native library. No need for `.run` etc.
P5 and P6 have been explicitly different languages since day one[1]. As Larry Wall said, "We had to make almost everything [in Perl 5] ... backward compatible [with previous Perls] ... But now it’s the first chance to [break bug-for-bug syntactic and semantic compatibility] and ... I think we should [take the chance]."
> There’s no compatibility between the two.
None?
With an appropriately compiled perl 5 binary installed one can install regular Perl 5 modules from CPAN and use them as if they were Perl 6 modules:
use Some:Perl5::Module:from<Perl5> ;
How is this not compatible?> You can’t write a library that works in both versions
Even the large complex Perl 5 package Catalyst works in both Perl 5 and Perl 6 per the above.
> so you lose CPAN and the thousands of packages that make Perl so powerful
Per the above, the majority of CPAN just works 100% correctly out of the box.
> If Perl 6 wanted backwards compatibility, they needed to have thought about it a long time ago.
P6ers thought about backward compatibility with Perl 5 from day one[1].
A lot of people seem to have forgotten, or maybe they weren't around for it, but when Larry anounced Perl 6 it wasn't for a totally different language. It was the next version of Perl. Just as Perl 5 was to Perl 4, and 4 was to 3 and so on. This idea that it's a completely different language and has no relation with 5 is something people started saying when it was clear that Perl 6 wasn't just around the corner.
... he very clearly emphasized that it was NOT just the next version of Perl, in contrast with his approach with earlier Perls.
> This idea that it's a completely different language and has no relation with 5 is something people started saying when it was clear that Perl 6 wasn't just around the corner.
I think it's just a chinese whispers effect.
To folk who paid attention to what Larry said on day one, it was obvious that P5 and P6 were (are) not the same and are not totally different either and are related.
Around a decade ago some folk began repeating the mantra that P5 and P6 were different languages in the same family. The hope was that this would help.
But some folk don't like nuance so they arrived at clearly made up and extreme views like "completely different language ... no relation with 5".
When they gave that up, they needed to work out a completely new plan for maintaining interest and driving adoption, but instead of reassessing they seem to have decided "who cares, it's gonna be so awesome that it won't matter." It might work, but I'm not holding my breath.
At best, it's a hack. Impressive, sure, but not something that you could rely upon. There's still no sane upgrade path here.
The same could be said for XS. And I do think that all of Perl 5 is relying upon that.
> There's still no sane upgrade path here.
FWIW, my blog post https://www.perl.com/article/an-open-letter-to-the-perl-comm... touches on that subject.
That said, why is it impossible to call a Perl 5 function in scalar context? Shouldn't the equivalent of Perl 5's "scalar" be fairly easy to implement? It may stink to have to manually use it, but it wouldn't be very often, and it's easy enough to use any of half-a-dozen Perl 6 features to minimize the syntactic hit.
I wonder if Fortran 2008 wasn't called Fortran, could it be sold to computer science people as a "fast, type-checked matlab".
Eventually one would use Perl 5 from inside Perl 6 with the "use v5" statement.
Perl6 has some compatibility -- at the wetware level.
Which is not nothing.