💾 Archived View for idiomdrottning.org › bad-language-contempt captured on 2024-05-12 at 16:07:21. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-02-05)
-=-=-=-=-=-=-
Great article overall! But this part specifically:
Other self-taught narratives, such as starting with Wordpress-based design backgrounds and moving from more simple themes to more complex themes where PHP knowledge is required, to plugin development is a completely valid narrative, but a path that is predominately for women.
I feel like it’s conflating two strands.
One, which is bullshit, is the whole “real programmers write directly in the hex editor”, close-to-the-metal, “LKML is the true elite”, “if you are not at the top, don’t bother taking a single step” narrative that needs to go away.
The other is… wishing PHP (and its libraries) was a better language. I started on really crappy languages too! BASIC, but my second language was Pascal—arguably an even worse language than PHP! It’s not that the route Wordpress→Templates→Themes→Plugins→Programmer is a worse route than Spreadsheets→VBA→Programmer or Games→C64→Basic→Programmer or DRM cracker→Machine code→Assembly→C→Programmer.
It’s that PHP (and Basic and VBA too for that matter) are bad languages (in some senses—they definitively have their advantages also).
As an analogy, if someone is learning how to ride a bike on a rickety and dangerous contraption, it’s not necessarily wrong to criticize the manufacturers of said bike! (Yeah, I know PHP is FOSS and that every piece of FOSS software is a precious gift, no matter what else. But that’s a story for another day.)
I started programming when I was 12 years old (I had read some programming books approx four years before, and had done some of the exercises on paper, but with an actual computer, that was when I was 12, 13 or so) and throughout my teens, I really had a fear of going out of my comfort zone. I didn’t wanna learn about switch case so I did tons of if statements. (Not that tons of switches is better—these days I’d just use a different structure altogether!)
I was very intimidated by learning about new libraries or even new languages, and that held me back. Learning about other languages and how they could be “better” is what prompted me to widen my horizons and get a deeper understanding on how programming languages even work in the first place.
Now, the article’s author isn’t alone in conflacting the two strands. They do tend to feed on each other in a bad way. The “real programmer uses such-and-such” narrative is harmful and it feeds on the “I’m just criticizing the language”. But.
Wouldn’t it be cool if blog platforms (or games or spreadsheets) were on an actual good language?
I’m not criticizing these students for taking this route! That’d be victim blaming. I’m not faulting the students for the road they’re taking, I’m faulting the road for rough and dangerous.
The article is kind of making the assumptions that all languages have the potential to be the same, to do the same things, they’re all Turing complete… but, as the song goes, “It’s kind of like construction work with a toothpick for a tool”. Different languages are good at different things, and, some are worse and some are better. That’s why there have been new languages invented in the first place.
Jos adds:
Languages can be good and bad, but it depends on the context in which we are using them. Basic, while probably not a great tool for a huge productivity suite, is awesome for a 12 yo. learning on a C64 (or whatever).
So OK, with that in mind, you’d want to judge PHP for its learning potential separate from its applicability for making web stuff.
I didn’t want to venture to far into the former (because I don’t want to throw too much shade on those who used it as their starting ground—coming myself from an awful language like QBasic and stuff like gorillas.bas—that didn’t get in the way of me later grokking lisp well). PHP is really bad as the latter—as a web language.
Looking at PHP as a learning experience, it also does teach some bad habits but, it teaches them in a clear and understandable way so there’s some pros to it there.
PHP’s big reason for stardom was being one of the first languages that appeared to be “embedded” in its target language. You’d write [what appeared to be] a normal web page with just a few lines of well-placed PHP where you needed it. This is easy enough to implement in other languages [a friend of mine, a real PHP hater if ever there was one, threw together something similar for Perl in an afternoon] but there’s something to be said for pioneering that idea.
It’s not necessarily a good structure for web dev (it mixes presentation and semantics), but, it provides a nice, smooooth learning curve from writing web pages / templates to writing actual code, and that’s awesome♥︎
That makes me look at PHP with kinder eyes. However, a good language presented in a similar “template” fashion would’ve been even better…? Although probably as derided because the template/“embedded” architecture itself has some issues re SPOT.