The product I’ve been working on for my new job is in Perl. I’m really into programming languages but I’m probably never going to pick a job based off of which one the company uses, partially because virtually no one uses any of the ones I like. I’ve never been a huge fan of Perl and my opinion of it has been going down since using it more substantially. There are lots of fiddly things I could explain about why I don’t like it but I haven’t been able to pin to the overarching, philosophical issue I have with its design. I came across this fantastic talk earlier by the creator of the Clojure programming language which really helped me nail it down.
In that talk, Rich Hicky draws a distinction between simple and easy. Even though they seem to have very similar meanings he goes back into their etymologies and uses them to talk about two different ideas. Easy meaning a much more subjective sort of thing and much more based of the familiar. Using the tools we know is easy but using the right tools will result in a program which is simpler.
According to Perl’s creator Larry Wall, Perl makes “easy things easy and hard things possible.” Lots of things about Perl will be familiar to those coming from a background in unix scripting, with some C based influence as well. Perl often seems to make things easy in a very complex sort of way. Take a look at all the rules for how Perl’s string interpolation works. Perl started by taking the convenient ability to do that with variables in unix shell and took it the logical extreme. String interpolation can certainly be nice but worth the cognitive load in trying to figure out those corner cases? The whole language is full of this kind of stuff.
I’ll take it over debugging seg faults in C++. Also, it does have some support for first class functions and some other nice stuff I always miss in C++ and Java. So far though, I need to devote way too much of my mental power figuring out what in the world Perl will do in various cases and that detracts from my ability to focus on the program.