Earlier quoted context omitted.
I don't see why not. It's possible to have done it any any mainstream language.
Which mainstream language would you have chosen in 2003 that you think would have had similar success?
Hack: a new programming language for HHVM
401–410 of 422 posts
Re: Hack: a new programming language for HHVM
#402Earlier quoted context omitted.
hm interestingly, PHP still powers about 70% of the web! the web should have certainly crumbled by now ...
I'd disagree if you say PHP powers about 70% of the web. Web servers (and all other kinds of servers) are not written in PHP neither are protocols that drive the web. Operating systems are not written in it either. These (and many more) are what power the web, not web applications. Your definition of what "powers the web" is remarkablly wrong.
What point are you trying to make?
Re: Hack: a new programming language for HHVM
#403Earlier quoted context omitted.
Why would you feel insulted? Did you personally create any of those languages? In fact, did you personally create any language? If not, maybe you should't be quite so dismissive of the accomplishment it was to create PHP. Sure, it's not the best language out there, and valid criticisms can be levelled at it, but as they say: It's better to have tried and failed...
What you just said is plain stupid. So our language designers can be critical of other languages? Bullshit! Since programmers can vote with their feet and gravitate towards better languages (is it miraculous that almost all programmers have a distaste for PHP?) we should give reasons why we use C and not PHP. If they were equally crappy what would have been the cause of choice of one over the other? I can call PHP th…
Re: Hack: a new programming language for HHVM
#404Earlier quoted context omitted.
I'm running multithreaded background processes in PHP pretty successfully. I did not see (and still do not see) a reason why I should have chosen another "proper" language for it. P.S. The vast majority of arguments against PHP here leads me to conclusion that most of (not all) debaters don't understand how PHP works well enough.
Mulithreaded using the pthreads api or something else? Any chance there's code I could take a look at (I'm curious!)
Re: Hack: a new programming language for HHVM
#405Earlier quoted context omitted.
> I am baffled as to why you'd build your castle atop a crumbling foundation. Because perfect is not the enemy of the good? Because "build atop a crumbling foundation" has demonstrated time and again to be, by far, the most successful way to accomplish anything in computing? Unless you have some example of perfect, now dominant, technologies that have been created ex nihilo that I'm missing? I mean we (facebook) are…
Given a programming task, it will be written faster, easier, and in a more maintainable and less bug-prone fashion if it is not PHP. The opposite opinion is basically indefensible. Sure, you can still dig a trench with a spoon (and if you have enough money to wield a bunch of workers with a spoon), even if a shovel would do a better job. Let's begin. 1) PHP autocraptastically converts strings that look like numbers,…
Option #2 ended up getting a lot of publicity for the engineers. If they chose option #1, not only is it a lot of hard boring and possibly error prone work, there is no chance for any of the engineers to get the type of publicity they are currently getting. All in all, engineers tend to work on whatever will make them get noticed, not necessarily the better technical choice nor what is in the best interest of the company... this is especially true in companies like Facebook and Google where there are a lot of very smart engineers doing relatively mundane work. So there you have it Hack/HHVM are all just publicity stunts, the more you feed it, the happier their PR gets.
Re: Hack: a new programming language for HHVM
#406Earlier quoted context omitted.
I'd disagree if you say PHP powers about 70% of the web. Web servers (and all other kinds of servers) are not written in PHP neither are protocols that drive the web. Operating systems are not written in it either. These (and many more) are what power the web, not web applications. Your definition of what "powers the web" is remarkablly wrong.
Facebook doesn't use web servers or operating systems written in PHP either, right? So if the language that web applications are written in isn't very important to the overall dependability of web applications, then it stands to reason that Facebook's choice of PHP for their web applications shouldn't be a problem either, right? What point are you trying to make?
I had this question in mind while reading your reply. What point are you trying to make with your comment? For my part I wanted to point out that it's unacceptable to say PHP powers 70% of the web. (Check my previous comment's parent.) It has nothing to do with Facebook. And I didn't allude to your inference that choice of language doesn't affect the overall dependability of web applications.
Re: Hack: a new programming language for HHVM
#407Earlier quoted context omitted.
What you just said is plain stupid. So our language designers can be critical of other languages? Bullshit! Since programmers can vote with their feet and gravitate towards better languages (is it miraculous that almost all programmers have a distaste for PHP?) we should give reasons why we use C and not PHP. If they were equally crappy what would have been the cause of choice of one over the other? I can call PHP th…
Given the widespread use of PHP for web programming, it seems obvious that in the domain of web programming, developers have voted with their feet for PHP.
Re: Hack: a new programming language for HHVM
#408Earlier quoted context omitted.
Mulithreaded using the pthreads api or something else? Any chance there's code I could take a look at (I'm curious!)
I use curl_multi_* functions.
Re: Hack: a new programming language for HHVM
#409Earlier quoted context omitted.
Given the widespread use of PHP for web programming, it seems obvious that in the domain of web programming, developers have voted with their feet for PHP.
Energetic amateurs. They've not reached maturity so that their votes should be counted.
Re: Hack: a new programming language for HHVM
#410Earlier quoted context omitted.
Engineer working on Hack here. You can actually write you example a bit more concisely in Hack: "$y ==> $y + 1".
Return statements are optional? So it's just the last statement in a function that'll get returned?
If the right hand side _is_ wrapped in curly braces then it is treated as a list of statements, in which case you do need to use the "return" keyword.