This is my view on Perl after coding occasionally with it for 2-3 years. For the last 6+ months i've been coding Perl 8 hours per day. In general i'd consider myself at least average in those languages (meaning this list includes my favorite language(s) and ones that i came across for projects and never looked back): C, C++, Java, Javascript, Python, Groovy, Visual Basic, C#, PHP.
To be honest i don't agree at all (actually i'm all for letting Perl die except for little scripts less then 100 loc):
Perl Programmers love their language:
Me (and colleagues) had to use Perl for some projects and i can't say i love the language at all. I understand it, i can write it and i am constantly underwhelmed, disappointed and sometimes disgusted. The point is that Perl is sort of a zombie in many businesses and runs often enough that it can't be ignored and often enough has to be maintained.
True Freedom:
Probably yes, but "and often can find the core developers in charge of some code" really doesn't apply anymore.. i browsed a lot through CPAN and a huge part of modules hasn't been touched for years (i can't count how many modules i've seen from 2001).
Great Community:
I certainly wouldn't bash a whole community, it sure may be great, but when searching online you get the feeling it died years ago (most posts are ooooold). perlmonks.org is often a good resource, but beyond that... the IRC channels i know are more idle then other languages (by far).
CPAN:
True, a big selling point for Perl is the huge amount of libraries on CPAN. But it's really untrue to say "there is nothing like it" (PIP for example).. Same point as above, a big amount of CPAN seems to be not maintained anymore, there are many modules with unsolved bugs.. just a few examples of widely used modules that haven't been updated for years and have open bugs:
Config::Simple https://rt.cpan.org/Public/Dist/Display.html?Name=Config-Simple
XML::Simple https://rt.cpan.org/Public/Dist/Display.html?Name=XML-Simple
HTML::Parser https://rt.cpan.org/Public/Dist/Display.html?Name=HTML-Parser (atleast active)
And i just went through search.cpan.org hit some "buzzwords" and checked the results, there is a BIG amount of modules nobody looked at for years.
I'm not saying that there is no development at all, but often enough i think "mhh, should i even use this module? Nobody seems to care about this anymore". Certainly the most important libraries are actively maintained for sure, no doubt about that!
Awesome Tools:
Yes sure.. Moose is a good example of what's wrong.. it's trying to bring object system to a language that wasn't even remotely designed to support modern language features. Not to bash Moose, i like Moose, it's good! But it tries to solve a problem that shouldn't be there in the first place.
Another creepy example:
Want to have exceptions in Perl? Turns out the language doesn't have them.. There are modules.. all of them do some black magic trying to emulate this. The number one google hit (Error.pm) even states "Using the "Error" module is no longer recommended due to the black-magical nature of its syntactic sugar, which often tends to break.".
And this is not some fancy 2011 language feature, it still isn't built in! What's also not built in? Perl thinks it's ok when you read an uninitialized variable. Want the script to terminate when this happens? You'll have to implement and change signal handlers and take care of it yourself when other modules try the same... ugh..
Want to know if an element is in an array? There are some hideous for loops you could do, but nothing like "if X in Y".. best thing: Most recommended way to do this is to convert your array to a hash/dictionary and check for the key.. that's basic array handling..
I could go on with this list for weeks but i fear this is already too long of a text..
Jobs:
Yes, where i live it doesn't matter. As IT guy it's unbelievable easy to get a job, that has nothing to do with the language. At least where i live.
My criticism on Perl:
- Perl lacks basic language features of a modern language (Exceptions, Array Handling, Error Handling, Unicode Support is horrible and so much more)
- In general Perl code from different programmers looks very different, because basic things can be done equally "well". This and a hideous syntax leads to really hard to read code unless you know every way a Perl program can be written (and i'm sure not even Larry Wall knows that)
My fun fact on Perl:
- Did you know that Parrot (the Perl6 VM) won't have a Perl5 interpreter because it's next to impossible to craft a 100% perl5 compatible parser.. at least they gave up early.
I've had the highest WTF-count while reviewing other peoples code by far(i may at one day put my prime example on thedailywtf.com).
Now this will get me a massive downvote, but this is my Perl experience. I can only beg people:
When your script/tool exceeds 100 lines of code, don't use Perl! Atleast not if there is the remote possibility of another human being having to understand or maintain it. Please!
[edited for some paragraphs, but well... not as readable as i'd like it to be, sorry!]