5 ms·
The problem with Perl is not the syntax, it's the semantics, or more accurately the loose connection between the two.
by tome 14y ago
The problem with Perl is not the syntax, it's the semantics, or more accurately the loose connection between the two.
- kbenson 14y agoExample? I'm interested in what you find ambiguous.
- snaky 14y agoI think this will be rant about the list/scalar context or scalar/array/hash context. Like a pointers in C that are extremely useful features and at the same time are surprisingly hard to understand for many people.
- kbenson 14y agoIf so, that would be a shame. There's already far to much "Hey, that's not how C behaves! [insert lang here] is stupid because it doesn't do what I expect, and I expect it to be C."
- snaky 14y agoI've lost you here. My C pointers analogy was relevant only in that is surprisingly hard to get by many people, and I don't know why is that so. The only thing in Perl that clearly imitates C pointers syntax and semantics is a hash/array reference element access '->' and I like it because it clearly distinguish from actual hash/aray access '.' and understandable for any person who knows C.
- kbenson 14y agoOh, I understood your meaning, it was just similar enough to another theory of mine[1] that I sort of launched into that frame of mind immediately. In short, people often expect other languages to act like C, and where they differ they get a bad rap (even through they often differ at that point for a reason, and it's often considered a strength by proponents). For example, caring about return context in Perl. [1]: https://news.ycombinator.com/item?id=5657901 https://news.ycombinator.com/item?id=5657901
- snaky 14y agoI think you get into the apple in quote you referenced, understand vs think they understand looks like core problem with many non-trivial and often actually very well designed things. Another example of this kind I see too often is a CPAN to <choose-a-language> guy. He thinks he understand what it is ("That's simple! Just a bunch of libraries packed in tar.gz available via FTP and HTTP, right? Oh, and there is the search field to find them, yeah. We also have such thing in <our-language> - see, ftp://..."). edit: Another good example is a Trackpoint clearly.