86 points · by nsoonhui · 3y ago · 74 comments
Pretty sure every year there's thousands of unnecessary search requests for this nonsense.
Programming languages are tools. Make it as easy and straightforward as possible so that its users can build whatever it is they were building with the least amount of friction.
> There are two reasons this term will stay. It is a tip of the hat to the amount of PHP work that came out of Israel
Funny because PHP — particularly theearlier versions — isn't exactly considered an example of good language design (though it has vastly improved recently).
> but you google it once in your life and then you ‘forget’ about it.
Negative. I had forgotten what it meant. All I remembered was that I've seen it years ago and was annoyed back then.
> And if you can’t remember the meaning of something like that, I hardly doubt you’d be a decent programmer anyway.
That's just, wrong on so many levels. Anyway, I'm just happy they didn't say anything like "people who screw up colons shouldn't be coding"
When nurses complain about the injuries and the inconvenience, you berate them because "if they can't remember that in room 4 there is a booby trap, are they really intelligent enough to be nurses?"
For a recent example, the MCAS design is nonsense, yet people were blaming the pilots, stating something along the lines of: "On page 837 paragraph 7, there's half a sentence that explains how to resolve the issue."
Forgetting to mention that the cause of the issue was purposefully omitted, and that the issue of unexpected trim change typically has a familiar and resolvable cause, not one that physically overpowers pilots... repeatedly. With delays. With no warning signal.
Even other pilots were blaming the dead pilots for making mistakes that were not humanly possible to avoid or recover from.
Maybe we need to add: "A superior aircraft designer uses their superior design skills to avoid situations which require a superior pilot".
There really are apparently "trivial" things in even vaguely modern (like maybe 50+ years old) aircraft that were not like that in 1940s or sometimes 1950s planes because even though we know they killed people the attitude was "You should just know about that". No, fix the plane.
Certainly for programming languages we need to be clear that bad error messages aren't a lack of knowledge by the programmer, they reflect poorly on the quality of the software.
But this applies generally across the design of everyday things. That push door with the word "PULL" written backwards? That's a bad design. Yes, I understand, I am reading a sign meant for people on the other side of the door, but you should have designed the door differently.
Or a thing that periodically annoys me: USB A plugs have the USB trident logo on them. The USB compliance rules say to put the logo on the "top" of the plug. So e.g. if you plug six USB A things into a typical laptop, the logo faces up on every port, the ports are all oriented the same way. So it ought to be very easy to insert USB A plugs when you can see what you're doing. Not perfect, but hey - except even some fairly decent brands decide their brand logo is more important than compliance, so e.g. this XBox controller plugged into a Windows laptop is "upside down" because they just couldn't bear to put the trident logo where the compliance rules said it needs to be...
So the bad design decision resulted from a bad business decision, which was the result of the whole incentive structure within the company, which was the result of the way that corporation operates (has to operate?) within a capitalist environment.
On another layer the regulators did not prevent the MCAS because they themselves have been influenced by economic incentives, lobbying and lack of expertise. In short: capitalism again.
If we wanna live in a capitalist society that is driven by such incentives, we need to be aware that the huge resources and big incentives for corps to take shortcuts and prevent effective regulatory overssight need a powerful counterplayer that is capable of keeping these entities in check.
How we go about that is a different thing, but anybody labouring under the illusion that a next MCAS could be prevented by market forces alone should go see a doctor.
A lot of those arguments read like they have a lack of empathy and desire to make things easier for new programmers who want to learn or use the language. To me, it comes across as if coming from a position of arrogance, especially the latter claim - a perspective that I've sadly have encountered often, with many people unapologetically being happy about their solutions or the status quo being being unapproachable or needlessly complex - be in regards to system design, code structure, or even how entire libraries (or languages) work.
Then again, even people like Richard Stallman and Linus Torvalds have been known to be difficult in certain regards. I'm not sure whether our industry seems to attract people who have strong feelings about certain things, or whether those beliefs are simply more apparent. Either way, you'll have to deal with that, either because of technologies that you need to use and don't have control over, or because of having to work on certain projects together with developers like that.
Best you can do is probably be as nice as you can towards others yourself.
Also, web archive link, in case the site is down (rate limited) for anyone else: https://web.archive.org/web/20221204044109/https://phil.tech...
Ah, the elitest assholery that made PHP a wonderful place to be /s
I would like for somebody to hardly doubt that I was a decent programmer. Unfortunately most people belong to the "highly" faction
This has changed by now, but the PHP maintainer community before version 7 was a circle jerk of hyper anal trolls.
If you can’t get something as simple as a colonoscopy right, you shouldn’t be anywhere near a terminal.
In all seriousness, it's interesting to see how the live language is diverging from the rules. The dual ending "-ayim" is supposed to be used with the singular stem: nekuda(-t) - giving nekudatayim "two dots", and likewise shnatayim "two years", dakatayim "two minutes", etc. But in practice, speakers classify dual as plural and use the form with both plural and dual endings: nekudotayim, dakotayim
There are not an unlimited number of acceptable methods for romanizing Hebrew.
take the Israel city of Petach Tikvah. Assuming you know about the gutural h in hebrew, you know how to pronounce it correctly via that spelling. However, that's not the official transliteration. The official one is Petah Tiqwa. And unless you know that the w should be pronounced like a v, most israelis (perhaps not those of yemenite extraction) will look at you strangely.
why transliterated weirdly? my understanding is that its meant to be able to go 1:1 programmatically back and forth between hebrew and english, so you end up with things that look weird to the english trained eye.
A confluence of issues like this lead to a highly idiosyncratic ecosystem - and hence to the negative view of PHP that many have.
Tying back to this particular story, parse errors don’t include tokens anymore since PHP 8
(Someone should also look at my PR for golang.org/x/net/trace from like 5 years ago.)
If it aint broke don't fix it. A PHP (horror) story - https://news.ycombinator.com/item?id=9485570 - May 2015 (7 comments)
PHP expects T_PAAMAYIM_NEKUDOTAYIM - https://news.ycombinator.com/item?id=8196690 - Aug 2014 (1 comment)
T_PAAMAYIM_NEKUDOTAYIM vs. Sanity - https://news.ycombinator.com/item?id=6356501 - Sept 2013 (2 comments)
unfortunately because i speak almost no hebrew i have to look it up every time
i think hebrew is fairly phonologically simple, isn't it
on glancing at the overview, the only thing that looks remotely challenging is that [χ] (כ or ח) contrasts with [ʁ] (ר)
even the vowel system is roughly the same five-vowel system used by languages like spanish (and nearly japanese), and both consonantal gemination and phonemic vowel length have been dropped in modern hebrew
we're not talking about something like keresan here
so what are you on about
This website has been temporarily rate limited
You cannot access this site because the owner has reached their plan limits. Check back later once traffic has gone down.
If you are owner of this website, prevent this from happening again by upgrading your plan on the Cloudflare Workers dashboard.
99% of the time the cause was: you are on PHP 5.2, but we're trying to use PHP 5.3 late static binding ( `static::someMethod()` ).
Parse error: syntax error, unexpected token "::"
https://3v4l.org/2T8qQWhy is "T_PAAMAYIM_NEKUDOTAYIM" any less valid than "Printer is on fire"?
An obscure in-joke makes sense when the system is used by the dozen people that will get it.
It quickly starts being annoying when you go mainstream.
If an error message says:
syntax error: unexpected {, expecting )
...I don't have to google anything. I know that there is a '{' that shouldn't be there, or that something else is missing before it, done.If the error message would instead read:
syntax error: unexpected NAMIKAKKO, expecting MARUKAKKO
...then I would indeed have to google it, unless I just so happened to know the japanese words for "wave bracket" and "round bracket"My point is: a good message about an error as simple as an unexpected or missing syntactical element can convey all the information I need to fix the problem, without requiring me to invoke a supremely powerful search engine, indexing the largest repository of collective human knowledge in existence, to make sense of it.
If you want to actually use PHP, or any other language, and the interpreter/compiler throws up errors that _cannot be understood_ by "using your brain" then that is both a bad design decision that should have been changed way back when, _and_ is a current bug in your interpreter/compiler that you need to fix.
As an alternative explanation, perhaps people don't want to be using Google to look up an obscure error message when they're in the middle of writing code, when the error message could be better and the history of the programming language is irrelevant to the problem at hand?
Here's the deal. Haskell has “Functor” (mappable), “Monoid” (aggregate/summary), “Foldable” (summarizable), “Monad” (context/commandlike). This language comes from a lot of early adopters being math nerds of a sort. It is a barrier to entry, and everyone understands that.
PHP’s situation is worse because, you know what's true about PHP developers? They are often just learning programming. It is an entry-level language, something you can throw into the HTML you already have to make some magic happen. Yes it can be so much more, but it ALSO is a lot of peoples' first look at programming. When you chose to learn Haskell you knew you were jumping in the deep end. The sitch with PHP is grown adults nearly drowning in a kiddie pool.
Look, when Haskell condescends to me, “Your rigid skolem type variables are bound by the type signature for fizzBuzz!” I know as a seasoned programmer that I am experiencing my own masochism and that I should probably Google away and that I may end up having to read a PDF by Dr. Craig T. Skolem to find out why he has a species of type variables named after him. But if you are just starting out? It just makes you feel like you will never be able to do this and why did you even try.
So keep T_PAAMAYIM_NEKUDOTAYIM in the error message, feel free, I don't care. But IF it is there, please include in your English error messages in some brackets, “(that’s Hebrew for ‘double colon’, it helps for searching errors online)” or something like that. If you find that line in the error message smug/condescending, then T_PAAMAYIM_NEKUDOTAYIM is all the more smug, because it has the same implications but hidden behind an extra smug superiority, “you don't know the history of this language, do you?!” Or, on the flip side, as long as the error message explains what went wrong and hints how to fix it, feel free to inject a mini Hebrew lesson into my day, sure.
It also allow you to use all the premutations of Address and Decrement registers: C[A|D]+R. How do you do this with "first" and "rest"? ;)
That said, the terms "first" and "rest" are superior, and one of the things I love about Clojure is that it never makes anything obscure.