3 ms·
Moreover, as often as people joke about the readability of Perl code, that's entirely a function of the developer. I've easily written tens of thousands of lin
by BaseballPhysics 3y ago
Moreover, as often as people joke about the readability of Perl code, that's entirely a function of the developer.
I've easily written tens of thousands of lines of Perl, and not a single person has complained about difficulty reading or maintaining that code. Why? Because I apply all the usual best practices for code hygiene that apply to any language.
Frankly, I think most people are just repeating a meme they heard once, and the rest just get put off by a) sigils, and b) the use of implicit variables (which I tend to use only very sparingly, and mostly in quick one-liners).
But a developer that poorly names their functions or variables, fails to modularize appropriately, fails to document their code, abuses language features because they want to be excessively terse or clever, that kind of person is gonna write crappy, difficult-to-maintain code no matter what language they use.
In fact, I'd argue the advent and popularity of Python--which was pretty radical in how opinionated it was at the time--is a direct response to languages like Perl and C that were a lot more free-form and easier to abuse by poor coders.
- tribby 3y agoabsolutely a response to perl. “TOOWTDI” has been an expression in the python community for a long time :)
- thesuperbigfrog 3y agoTIMTOWTDI is Python's motto for managing dependencies and deployments: https://packaging.python.org/en/latest/overview/ https://packaging.python.org/en/latest/overview/ <kidding> OCI (Docker) Containers were invented to overcome the problems inherent with deploying Python applications. </kidding>
- yjftsjthsd-h 3y ago> that's entirely a function of the developer. I would argue the same of sed/awk; you can write an unmaintainable mess, but you don't have to.
- BaseballPhysics 3y agoOh sure. IME Perl just pulls it all together into a much more convenient, all-in-one package that has all the libraries and tools you need to build anything from small scripts all the way up to large projects.
- zgluck 3y agoand not a single person has complained about difficulty reading or maintaining that code Developers extremely seldom complain about other developers' code to their faces. Instead they go to lenghts to avoid it if they dislike it severely; right or wrong.