Hacker News new | ask | show | jobs
by jasongill 650 days ago
This really does not come as a surprise. PHP 7 erased the performance gains that Hack had, and PHP 8 brought a lot of the last few missing pieces that helped modernize PHP.

Hack was heavily optimized for Facebook-sized setups and was never intended to run in the places that PHP is most often run from (such as cPanel servers), so it never really picked up much traction among the PHP world.

Non-PHP developers never even considered it as an option, as they probably didn't consider PHP as an option either.

Basically, it was one of those projects that may have been a good idea when it was released (although perhaps just contributing more to PHP might have been the better thing for Facebook to do, but that's a different story), and it's time has now passed. I'm just surprised it took this long for them to end work on it, honestly

1 comments

Does PHP have async/await yet? In my mind that was always a huge advantage of HHVM/Hack which normal PHP completely lacked.
Thankfully, no - IMHO, PHP doesn't need non-blocking or asynchronous execution, as that's what makes it so accessible and understandable
Huh, I'm surprised by that take. await is one of the easiest-to-comprehend and readable approaches to concurrency. Slack summarized this better than I can, see the async/await section of their post https://slack.engineering/hacklang-at-slack-a-better-php/

Without async/await, PHP will remain a bad fit for large-scale applications that need to query data from numerous distinct services or data stores for a single page load without incurring major latency. It was an absolutely essential feature of Hack at Facebook. Lack of async/await in PHP was a huge problem at Tumblr when trying to reduce latency.