Hacker News new | comments | show | ask | jobs | submit login

Python and Ruby both have garbage collectors and can deal with reference cycles. Perl only has reference counting, leading to programs that leak memory due to reference cycles and needing to hunt down where in the code you're creating them.

It's the only high-level language I know of that only has reference counting for memory management.




and because of that, it often runs much faster, as well. Having an interim choice between "full GC" and "malloc/free" is a nice option, in some cases. Particularly for small programs/scripts that churn through a lot of data (so long as you don't build a cyclic graph data structure while scanning)


> It's the only high-level language I know of that only has reference counting for memory management.

It's also the only high-level language I know of that can't really be parsed ("only Perl can parse Perl" they say).

It's a dead language really, you can also see this from the number of noisy evangelists vs. professional users nowdays (and that comes from someone who has used Perl almost exclusively for the past 10 years), if you couldn't see it from the diminishing quality of important modules on CPAN (e.g. I pulled my hair today over JSON::XS generating '-inf' from values on one side and crashing on the other side while trying to parse it).

So, I'm learning Go now and improving my JS skills.


"you can also see this from the number of noisy evangelists vs. professional users nowadays"

Actually, where I work, we use Perl almost exclusively. I don't know a single person who I would consider a "noisy evangelist" - we just quietly get stuff done.


Maybe the noisy evangelists are the only ones with enough confidence to publicly proclaim that they use Perl. The others lack confidence and don't publicly announce it because the general programming community responds with disdain / pity.


Nah I've never met anyone in the Perl community who seemed to care much about what other people thought about their language choice. Also most Perl developers I've met tend to be polygots so they're less likely to be the yelly "THIS IS THE ONE TRUE LANGUAGE" type.

There is a Steve Yeggie quote, though its not necessarily praise for Perl, which always pops to mind when people have a rant about Perl:

'As I've done for a great many other programming languages, I've bashed on Perl's technical weaknesses at length in the past. To my continued amazement, the Perl folks are the only ones who never get upset. They just say "Haha, yeah, boy, you're right, it sure is ugly. Heh. Yeah, so, um, anyway, I'm going to get back to work now..." It's awesome. I've gained so much respect for them. It's almost enough to make me go back to programming in Perl. Well almost.'

Edit: Quote reference: http://steve-yegge.blogspot.com/2006/10/egomania-itself.html


I agree with your bet on JS and Go.


Even though the lack of a garbage collector is a factor, I doubt that it is the biggest reason.

I was bit quite nastily by the lack of garbage collection in Perl just a couple of months into using it.

However, perl proved itself as an invaluable tool for quickly trying out ideas, and I was loyal to it for at least 10 years. Perl just wasn't able to grow as strong as the alternatives did.


It's strange then that memory leaks seem to be much more prevalent in Ruby than it is in the Perl world?




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | DMCA | Apply to YC | Contact

Search: