Where are the Perl-hating trolls coming from on HN?
(I thought Guido said that it was time to stop trolling, so it isn't Python people now?)
I don't hate Perl (I first learned CGI programming with it), but I do think there are better ways to write maintainable, enterprise scale software. There are two main problems with Perl (as I see it): 1) The language is so permissive that it allows newbs to write bad code but still obtain results. Habits, both good and bad are learned! 2) Perl experts seem to delight in writing code that's "tricky" (for lack of a better word). It's like a contest to see who can wring the most out of one 80-character line of code and it leads to mid-to-low functioning Perl programmers being confused.
I can't see any relevance for a professional choice if newbies can shoot bigger holes in their foot with a certain tool.
That is a natural result of a powerful tool.
>> Perl experts seem to delight
Anecdotal. Ten years old description of half humorous use (and exercises). Also very different from best practices even then -- and especially different from how many/most work today.
Let me also note: If Perl wasn't better in many ways, you trolls would make serious arguments instead of "experts seem to delight"... [Or as you wrote above "Twenty-five years already? Now it can retire with full benefits."]
But I'll bite a little. Perl has the best OO system of all the scripting languages (Moose). The CPAN is the gold standard for scripting languages (and probably everything else). The testing culture is afaik second to none. The same goes for Unicode support. And so on.
In professional environments or large projects, hopefully you're got a reasonably comprehensive style guides (or better yet, perlcritic config), but for smaller things, it can be a bit of a struggle to understand and conform to the specific style in question if you're trying to contribute to something new.
I don't think it's enough of an argument to dismiss the language though, and agree that the benefits far outweigh the somewhat-pointy learning curve.
[1] The old "Everyone uses 10% of C++, but they all have a different 10%" joke, basically.
I never claimed that Perl wasn't powerful ... in fact I think I stated the opposite. Where I work, Perl is the lingua franca of the ops team and they certainly get things done. But the newbies don't shoot holes in their foot ... they blow it clear off and often don't survive.
My comment above may be perceived as a bit trollish but I was also thinking about "thanking Perl for a job well done". I quit Perl for what I consider valid reasons (which you completely dismiss - My experience may be "anecdotal" to you, but it's still my experience) which you're clearly not going to agree with. But notice that I never said "you shouldn't use it". I'll even admit that some people accomplish a lot with it ... and that CPAN is almost the gold standard for everything (with the exception of Maven Central I think).
So keep using Perl if you want ... but hopefully now you'll understand those of us that will no longer use it and why it's popularity is declining (http://www.tiobe.com/index.php/content/paperinfo/tpci/index....). I expect I'll replace my current tools with something better (more productive/safer/maintainable) in the next 5 years since that's been a continuing pattern for me. What will you be using in 5, 10, 15 or 20 years?
As I quoted, you also posted another obvious troll comment. So the shape of your ears and body odour are quite obvious through the screen...
>>My experience may be "anecdotal" to you
I just note the lack of modern references for your "non"-anecdotal claim.
I can give references to modern practices -- it is enough with the Best Practices book (it is seven years old...)
[As mst noted, the "Modern Perl" book is a very good reference.]
(Stopped reading after that.)
I am not posting this to bag on Perl, but just to show its fingerprint. If you find that periodic table to be funny or cool then you are a lot more likely to be happy with Perl than if it makes you shudder.
That point has been made many, many times.
Edit: To the cultural question, there might be a point. I might add that I don't know Perl 6, but it seems like an insane amount of cool/fun toys (macro language like lisp with an Algol-like syntax?! If they can pull that off it is incredible.) That might say something about me and Perl people. But people I admire use both vim and Windows, so I'm not certain.
But you are in denial if you think that this chart isn't a reasonably representative cultural artifact of the Perl community and the Perl aesthetic. Perl 5 is not exactly poor in operators, and it is the same core community which produced both.
I don't think that Perl is bad. I am saying that Perl is very strongly what it is. And while some people won't like that aesthetic, I don't see why anyone should apologize for it.
$ perldoc perlopJust an anecdote: a startup I work with built a product on Rails 2. It has been successful beyond anyone's wildest dreams. But they have a huge mess on their hands now, and it was caused by -success- :)
How is this different than any other language? You can write bad code in any language. Perl might allow for more obfuscated code which really makes it harder to read - but that again reflects on the programmer - not the language. Take a look at a code in PHP, Python, C, or any language written by "newbs" and you will see poor practices used everywhere.
Modern Perl and other recent books push people towards developing good habits.
The current generation of experts tend to either put our tricky in very well encapsulated CPAN modules, or comment the hell out of it, or both ... or if at all possible, stick it into a paste site somewhere for other people to go "whee!" at and do something sensible in the main codebase.
Your complaints about perl were absolutely valid a decade ago ... these days there's still some truth to them, but we've grown up a lot since then :)
I won't explain myself, smoyer's example (except the 'hate' part) pretty much sums up what I think about Perl. And yes, I believe it's a great language, although looking from a state of development of modern languages point of view, objectively speaking, it's a bit outdated language. And therefore, in my opinion, will find less and less applications in the future (and yes, Python is and will be its main competitor in many fields).