News for hackers. Stuff that matters.
Re:Why Perl? by tokai on Monday June 12, 2023 @10:20AM (#36293883)
What? The Perl 6 debacle has gone down even worse than Python 3.
Re:Why Perl? by G3rn0ti on Monday June 12, 2023 @11:24AM (#36295115)
Perl 6 took longer than expected but „Raku“ is alive and well. It even moved into the Tiobe-Index at rank #48 recently:

https://www.tiobe.com/tiobe-index/

This whole Python/Perl competition was always a bit silly. Both languages had and have their place. I would say Python is so much more popular because it found a niche in ML because of how much more easy it is in Python to interface fast C modules. So you get to write simple Python programs leveraging blazingly fast math libraries. That was always a bit more tricky to do in Perl.

But Python as a language is definitely not as flexible as Perl 5. Last time I checked Python didn’t even support multi-line lambdas because its inventor hates those. Python is very much designed in a top-down approach and tries to guide all Python programmers into how there are supposed to solve their problems. Perl 5 was designed with its famous „easy things should be easy, hard problems possible to solve” philosophy. It allows for meta-programming in all the right places which a seasoned Perl developer can reach to when necessary. Perl 5 is a nice middle way between C and Lisp.

That being said modern JavaScript turned into a powerful language that fits well into both the frontend and backend side of a web application nowadays and, hence, kind of replaced Perl as glue language for the web. It will also push Python out of web backends at some point I believe.

Re:Why Perl? by achileas on Monday June 12, 2023 @03:08PM (#36299300)
Having used Python and Perl professionally, I'd have to agree with really all of this. I just want to emphasize Python's niche in ML (since that's what I do with it mostly lately) - it was also helped by a large, early set of libraries specifically for ML that other languages either still don't have or are playing catch-up (Elixir), and its ease of use among academics, a lot of whom went straight from academia to industry.
Re:Why Perl? by b1c837696ba28b on Monday June 12, 2023 @11:48AM (#36295485)
Really? Was Perl 5 deprecated with prejudice across ecosystems, forcing projects to work with a janky, still-evolving replacement well ahead of production-grade stability? Because the boot marks in my ass from the forced march to Py3 are still bleeding.
Re:Why Perl? by wwweston on Monday June 12, 2023 @12:20PM (#36296019)
Perl 5 has been usable and improved on continuously over the last 20+ years.

Raku / Perl 6 has been the R&D project it set out to be with interesting new features and smoothed out syntax.

You can use either freely as meets your needs. If there's a "debacle" here it's the misunderstanding.

Re:Why Perl? by Woodi on Tuesday June 13, 2023 @09:15AM (#36309803)
What ? First Perl6 wasn't meant as replacement for Perl 5, v5 was meant to stay forever, maybe to be improved when possible. And that we have.

Perl 6 was meant as the bravest experiment with C-like syntax in 30(?) years - attempt to nicely mix few programming paradigms and styles. And that we really have in Raku.

They was talking "Perl is dead" but it never was and isn't. Maybe it looked as clinically death with out of body experience into ideal language heavens but since decade or so it is back. Solid and backward compatible as always.

And there was problem for some with "parallel language versions" marketing so Perl 6 was renamed to Raku. The harder question was "Which one I need to learn ?", but it is newbie programmer question, you need to know many languages because it is standard programmer life experience. And it is XXI century and many technologies are around.

On the other hand Python usage is scientifically researched as being a "write abandonware" language :)

Re:Why Perl? by lizmat on Tuesday June 13, 2023 @09:25AM (#36309908)
> Perl6 wasn't meant as replacement for Perl 5, v5 was meant to stay forever, maybe to be improved when possible. And that we have.

Sorry, but originally it was meant as the replacement (and I was physically present at its announcement at OSCON in 2000). It wasn't until 2008 when the "sister language meme" was generally accepted, that the paths diverged instead of being sequential.

Re:Why Perl? by Woodi on Wednesday June 14, 2023 @01:41AM (#36321884)
Ok, Perl6 was meant as new lang version. And replacement.

Ok, multi-lang virtual machines wanted to replace Perl5 binary.

But: :)

- multi-lang vm's are proof that v5 syntax wasn't mean to be eradicate at all cost

- there was no plan or push to instantly obsolote, uninstall and deny of Perl 5 usage

- I'm sure there was a conviction that some Perl 5 installations will stay for long time period into the future. Or as long as possible ~~ forever.

So it wasn't like Python 2.7 replacement. And plans even assumed continuation. And some from the start wanted to have both langs :)

Re:Why Perl? by lizmat on Monday June 19, 2023 @07:51AM (#36389960)
Indeed. The original plan envisioned Perl being a slang in the Raku Programming Language. That plan failed because Perl is largely dependent on C-code plugins that are used whenever Perl is considered to be too slow (which is often). So being able to support Perl syntax in Raku, would only allow use of Perl-only modules from CPAN (of which there are way too few).

To counter that, Inline::Perl5 (https://raku.land/cpan:NINE/Inline::Perl5) was developed. It gives you access to 99.9% of Perl's functionality transparently, such as being able to subclass Perl classes in Raku, and vice-versa.