News for hackers. Stuff that matters.
Re:PHP Almost Generics: Guided Journey Through the Official ... by dado3212 on Thursday September 25, 2025 @01:51AM (#45369665)
I'm glad that PHP has adopted more and more from Hack, Facebook's once fork and now completely separate language - https://hacklang.org/. It was never going to replace it (Go's success separate from Google has astounded me to be honest) but it heavily influencing PHP's direction feels like the best of both worlds.
Re:PHP Almost Generics: Guided Journey Through the Official ... by andrewjf on Thursday September 25, 2025 @03:11AM (#45370067)
What do you mean “separate from google”? Golang’s success is directly and exclusively based on google envy back in 2009-2012.
Re:PHP Almost Generics: Guided Journey Through the Official ... by lmm on Thursday September 25, 2025 @03:22AM (#45370125)
Their point is that Golang has seen adoption and use outside the Google ecosystem, which is perhaps surprising, and something few other "company languages" have managed (e.g. Swift is actually quite a nice language design, but almost no-one uses it unless they're deeply involved with the Apple ecosystem).
Re:PHP Almost Generics: Guided Journey Through the Official ... by 0x073 on Thursday September 25, 2025 @03:45AM (#45370257)
Swift started as closed source language exclusive for apple devices. Apple never was developer friendly outside of their ecosystem.

If I think about swift I think about ios apps (I know it can be more today, but their marketing for this language wasn't good).

So apple never wanted big adoption outside of their devices.

Re:PHP Almost Generics: Guided Journey Through the Official ... by hnlmorg on Thursday September 25, 2025 @04:00AM (#45370357)
Sure, if you forget about C, Java, TypeScript, SQL, and many others.

Swift isn’t gaining much adoption because Apple aren’t putting much effort into promoting its use outside of the Apple ecosystem. And why would they when they don’t care about non-Apple stuff

Re:PHP Almost Generics: Guided Journey Through the Official ... by lmm on Thursday September 25, 2025 @07:35AM (#45371643)
> Sure, if you forget about C, Java, TypeScript, SQL, and many others.

C has had multiple implementations from multiple implementors for decades. Java wasn't really tied into Sun's ecosystem, and had an enormous marketing blitz. TypeScript was even less of a Microsoft "company language" - and I think it's interesting that Dart felt a lot more tied into everything Google was doing, but ultimately lost out.

Re:PHP Almost Generics: Guided Journey Through the Official ... by hnlmorg on Thursday September 25, 2025 @04:15PM (#45378386)
Go isn’t tied to Googles infrastructure any more than any of the other languages.
Re:PHP Almost Generics: Guided Journey Through the Official ... by lukaslalinsky on Thursday September 25, 2025 @06:05AM (#45371063)
Go has two things going for it, it was created by legends, so it gained a lot of interest from the beginning, and it has an excellent and unique runtime, making it really ideal for network services that constantly wait for something, yet still being able to do CPU intensive work. The language itself is just "OK" and that's kind of the point of it.
Re:PHP Almost Generics: Guided Journey Through the Official ... by NeutralForest on Thursday September 25, 2025 @06:22AM (#45371210)
I think being able to just create cross platform binaries + having good tooling out of the box as well. You can get started with go very easily and sharing programs as binaries just removes a whole lot of issues you'd have in other languages.
Re:PHP Almost Generics: Guided Journey Through the Official ... by zerocrates on Thursday September 25, 2025 @03:24AM (#45370135)
I think they mean success in terms of Go being used outside Google? Versus hack/hhvm which had a pretty narrow window where it saw some limited outside adoption.
Re:PHP Almost Generics: Guided Journey Through the Official ... by that_guy_iain on Thursday September 25, 2025 @02:01AM (#45369715)
I think Facebook just forking the language instead of helping with development gave them the kick up the ass to sort out the development process. Then it just came down to having no one actually working on the language, so they needed to create the PHP Foundation to pay people to work on it because all the major companies left it behind (Yahoo, Facebook, Zend, etc). So it's good to see it managed to survive that chaos and become a pretty good language.
Re:PHP Almost Generics: Guided Journey Through the Official ... by dochne on Thursday September 25, 2025 @03:25AM (#45370142)
The foundation is a very recent affair.

The real improvements all came from the hard work of the developers who were around during the 7.* releases who did excellent work.

Most importantly at that time we had Nikita Popov who was incredibly helpful.

Hack/HHVM definitely gave it a nice kick of motivation though.

Re:PHP Almost Generics: Guided Journey Through the Official ... by gabesullice on Thursday September 25, 2025 @02:11AM (#45369759)
For an actual view of the syntax not behind a sign-in wall: https://thephp.foundation/blog/2025/08/05/compile-generics/
Re:PHP Almost Generics: Guided Journey Through the Official ... by cheshire_cat on Thursday September 25, 2025 @04:01AM (#45370366)
Re:PHP Almost Generics: Guided Journey Through the Official ... by patates on Thursday September 25, 2025 @03:02AM (#45370007)
Is this just a book promotion? Some text also gives me AI vibes.