Live data from Hacker News

Perl 7 is going to be Perl 5.32, mostly

perl.com

511–520 of 573 posts

Re: Perl 7 is going to be Perl 5.32, mostly

#511

Earlier quoted context omitted.

> it is not the notorious "write only" language that many troll it to be I dispute that. I have worked with many languages, and Perl has always been one of the hardest to remember due to non-standard symbol abuse and a few strange semantics. There is a reason it has that reputation. Even writing it isn’t easy. I can describe the Python syntax after years of not using it. Perl? No way I remember it.

Understood. I stated that to say my problems with perl is not the language itself. To say it is the "community" is not right either. But basically "what is left of the community" is the issue. Languages like python, ruby, perl, etc are only good (if you want to freelance and make money at least) at being a "skin" around a database. That also entails a knowledge of frontend frameworks and workflows as well. Yet the wo…

Well, I've given talks on databases (Postgres), javascript (vue) and modern devops (k8s etc) at various Perl conferences in the last years, so I cannot agree.

In fact, I'm giving a small talk on Docker today at the Perl Conference in the Cloud, and also a lightning talk about a ~50 line tool to provide an async web server to post to Matrix. https://tpc20cic.sched.com/

Yes, there are a few people entrenched in old ways (and sometimes it pays off to not always use the newest tech), but there are also a lof of Perl devs doing current stuff.

Re: Perl 7 is going to be Perl 5.32, mostly

#512
post #445

Earlier quoted context omitted.

> and it’s hard to impossible to find Perl programmers Which I'm finding harder to understand as I learn more languages. Yeah, every language has its differences and idiosyncrasies, but as long as you have access to docs (if not third-party resources like expert blogs or Stack Overflow) it's pretty straightforward to figure those out and be reasonably productive relatively soon. That is: a senior programmer should ha…

> Python, Javascript, or C# Those are all pretty basic Algol-family languages (at least if we're talking vaguely modern Javascript). If you were thrown in to J or Forth or Erlang you might have a different experience.

Funny enough, Erlang is my preferred language (or at least one of them).

I don't know if I'd necessarily call the JS in question "modern", though. It's running on RhinoScript, which needless to say ain't exactly the latest hotness. Still, the platform in question does happen to support/encourage AMD modules (with some special comments for certain components), so I guess it could be worse.

Re: Perl 7 is going to be Perl 5.32, mostly

#513

Earlier quoted context omitted.

I think it was really Perl 6 that killed it. Perl had a significant lead over Python, and the Perl 6 announcement just sucked the life out of it.

It wasn't the language, it was Numpy. Everything that is built on top of Numpy is what made Python so popular. And I guess Perl also never had its Django (or Rails).

In my opinion, those are results of Perl losing mindshare. Numpy is not exactly hard (R has a significant fraction built in, and there's an old standard library for Scheme, of all things, that is very similar). Perl was perhaps the leading language for websites, but the Perl 5/6 situation just confused everybody as it dragged on, which made Python and Ruby libraries seem more attractive.

Re: Perl 7 is going to be Perl 5.32, mostly

#514
post #496

Earlier quoted context omitted.

Both. Perl is around 20x slower than C for common tasks, while Python is around 133x slower than C for common tasks like looping, depending on what you're doing of course. Perl is the ultimate mockup language in that you can crank out code very fast and get good bug free results. It lets you write in the way you think where other programming languages force you to write a specific way. Ofc you can get good at Python,…

Don't forget about PyPy, which may well be faster than Perl (I haven't compared them) or Cython if you're stuck with CPython.

That's a good point.

I tried googling around and couldn't find any speed comparisons between the languages, just talk between the two like eg https://news.ycombinator.com/item?id=8626131

So, I guess I'll address this directly:

The tasks Perl is designed to do are different than the kinds of tasks PyPy is designed to do, so it is a bit of apples an oranges comparison.

PyPy starts to get its speed benefit when a task takes 1) longer than 3 seconds to run and 2) Is directly written in Python, not using libraries written in C.

Perl is designed to parse large files, do string parsing, and one off scripts. It being fast is nice, but it's not designed to be running large math heavy processing scripts to begin with. If a Perl script takes longer than a second to run, not including IO limitations and network limitations, it may not be the ideal tool for the job.

So while PyPy gets comparable to Perl speeds, Perl being fast is almost moot, because it's not designed to be used that way to begin with.

Re: Perl 7 is going to be Perl 5.32, mostly

#515
post #442

Earlier quoted context omitted.

Both. Perl is around 20x slower than C for common tasks, while Python is around 133x slower than C for common tasks like looping, depending on what you're doing of course. Perl is the ultimate mockup language in that you can crank out code very fast and get good bug free results. It lets you write in the way you think where other programming languages force you to write a specific way. Ofc you can get good at Python,…

> Ofc the Perl is going to look like garbage and not be maintainable Please stop perpetuating this myth. It really depends how you write it. Perl isn't going to do the tidying up for you, you'll have to properly structure the code yourself. If you still write Perl code like it’s 1991 then maybe itcs not maintainable. I work on a largeish Perl code base and I can assure you it's quite maintainable, moreso than most Js…

[deleted]

Re: Perl 7 is going to be Perl 5.32, mostly

#516
post #399

Earlier quoted context omitted.

Do you mean faster to write, or faster to run, or the combination of both?

Both I would guess. Perl in serial is already faster to run than Python, and as soon as you start using threads Perl blows Python straight out of the water. The only reason that stuff like tensorflow or numpy is not as dog slow as the rest of python is that they are bindings to c(++) or fortran libs. Writing faster is debateable, but Perl has tons of niceties like embedded regex syntax, string interpolation, one-line…

>Perl in serial is already faster to run than Python

Not it isn't.

>The only reason that stuff like tensorflow or numpy is not as dog slow as the rest of python is that they are bindings to c(++) or fortran libs.

So if I make a foo.py file and run the code, it runs faster. "but it's really c(++) or fortran!" doesn't matter in the slightest.

Re: Perl 7 is going to be Perl 5.32, mostly

#517

Earlier quoted context omitted.

I don't think your performance numbers are very accurate. I've done a bit of Perl and a lot of Python and they're fairly comparable in most cases. Python is lightning fast for a lot of scripting tasks and I generally use very few libraries for day to day tasks because the Python stdlib is so good. Unless you're doing something really simple with Perl command line switches that operate over an entire file, I'd bet Per…

> I don't think your performance numbers are very accurate. Food for thought. https://benchmarksgame-team.pages.debian.net/benchmarksgame/...

More food for thought: https://bitbucket.org/ewanhiggs/csv-game/src/master/README.m...

Re: Perl 7 is going to be Perl 5.32, mostly

#518
post #403

I've been a perl zealot since 2005. I didn't even know "python" existed until around 2008 when I found a script file with a ".py" file ending in a fresh ubuntu install. I started going to perl conferences sometime after 2010 when someone on irc informed be about them. I learned so much in those conferences, mainly about the alternatives to cgi and the modern OOP "framework" named "moose". I thought I was in heaven. I…

I feel you. I'm currently at a startup that, somewhat by accident, ended up writing their backend in PHP. Modern PHP is actually fine; it's largely avoided the issues perl has; adoption of the latest versions is quite high, and it's...fine. Not the best, not the worst, broadly comparable to other languages, and a far, far, far cry from what most people may think of when they hear "PHP". My last job used Node, the one…

It was self inflicted damage.

PHP 5 felt like two distinct languages - PHP 4 and Java parts. PHP 4 was ok for its tasks, Java parts bolted on top, very unnatural, no continuation. In essence community was subverted. Other prominent examples - pulse audio and systemd. Compare it with Perls "bless" - looks so elegant and natural.

Some people do not buy that change, stick to origins and it makes sense. There was a conference talk "most programmers don't change their habits, wait until they die". It takes many years to burn and bury those who remember. It is said Moses wandered with his people for 40 years (until no those who were slaves left).

If Java was bolted on top of Ruby today I would not stay. At least because Java is better than Java bolted on Ruby.

You have valid point - stuck in the middle there is no way but forward, burn the past. They have point - someone destroyed the language they liked and you is one of them. No one shames bash scripts for lack of engineering principles, unit testing etc. Please do not disrespect them, it is not their fault.

Re: Perl 7 is going to be Perl 5.32, mostly

#519

Earlier quoted context omitted.

Perl’s lunch was eaten more by Ruby IMO. The bifurcation happened as the Perl programmers that wanted a more traditional OOP system picked up Ruby and the folks writing Bash++ oftentimes went to Python. These days it seems like Ruby is where Perl was in 2010.

These days it seems like Ruby is where Perl was in 2010 It's more "mature" than "abandoned" IMO. I think it's in a solid place. A lot of Rubyists have moved on but so far, that's OK with me. Unlike OP's experience with Perl, most legacy Ruby and/or Rails codebases are not too disasterous.

That's probably because Rails hits the sweet spot. It's just complex enough to support a medium-sized website well. Most innovations since Rails have targeted high-load websites.

Re: Perl 7 is going to be Perl 5.32, mostly

#520
post #435

Earlier quoted context omitted.

> A few years later one of the newer employees on the customer support team started spouting off about "python" and how it was so easy to learn. He was always blabbing about terms I'd never heard of like "generators", "list comprehensions", "decorators", etc. I looked them up and learned they were just abstract constructs with fancy names that are supported in most any language. So I just figured he was some idiot th…

> You don't see how this is the same thing? No.. but feel free to explain. With my friend that left for google, I was annoyed at him somehow thinking python was advanced just because he was using stuff you could do in any language only he thought more highly of it because of the names. He saw the light of having a clean syntax, I did not, but now I do. If you look at the history of python, it is an "engineered" langu…

Pythons "there is only way" is too stiff for me. It may sound nice but in reality does not work, on top of my head - package managers, slots, itertools vs array comprehension, discouraged lambda, and whole python 2 or 3.

A sample of Google Python code I've tried to fix recently [1]. A ton of nothingness. You can produce it in any language.

You are too harsh on Perl design. I thought ruby was popular because it is great language. Nope. Cool kids moved to server side JavaScript. And tried to hide prototype oriented origins, they've added class friends privates now and a ton of other questionable features.

It is all about version 5 dead. I've red Perl 6 Apocalypses, I'd ship. Too bad there was no smooth transition path.

[1] https://github.com/GoogleCloudPlatform/gsutil/blob/master/gs...

Post reply on HN