Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
PHP Programming

PHP Finally Getting a Formal Specification 180

itwbennett (1594911) writes "Despite becoming one of the most widely used programming languages on the Web, PHP didn't have a formal specification — until now. Facebook engineer and PHP core contributor Sara Golemon announced the initiative at OSCON earlier this month, and an initial draft of the specification was posted Wednesday on GitHub."
This discussion has been archived. No new comments can be posted.

PHP Finally Getting a Formal Specification

Comments Filter:
  • by Tailhook ( 98486 ) on Thursday July 31, 2014 @02:46PM (#47576073)

    Yes, which is probably why this is coming from a Facebook engineer. PHP is pretty central to Facebook and Facebook has been re-implementing PHP for many years now. Facebook created a PHP to C++ translator (HPHPc) which has since been deprecated in favor of a new PHP virtual machine; HHVM. So Naturally formalizing PHP is of great interest to Facebook.

  • Re:Engineer? (Score:5, Informative)

    by OzPeter ( 195038 ) on Thursday July 31, 2014 @03:03PM (#47576263)

    Facebook engineer and PHP core contributor....

    My father in law in an actual engineer

    As an actual engineer as well, this sort of inflating of titles is a peeve of mine right now. It makes job searches nigh impossible as every position out there has the word engineer in them, and all recruiters seem to be doing nowadays is matching keywords - sort I keep getting emails about 'engineer this' and 'engineer that', when they are totally irrelevant to any sort of genuine engineering position.

  • by Daniel Hoffmann ( 2902427 ) on Thursday July 31, 2014 @03:07PM (#47576309)

    A formal specification is useful for the implementers of the languages to guarantee that your code runs the same across all implementations. It is pretty important. It should define all use cases possible and highlighting the "undefined" use cases.

  • by gweihir ( 88907 ) on Thursday July 31, 2014 @09:56PM (#47578873)

    A formal specification is a specification done in a formal specification language. There is no other meaning of that term. The people claiming they are doing a "formal" specification likely confused this with "exact". These two concepts are orthogonal. A formal specification can be inexact (or even unsound), while an informal specification can be exact (and sound).

    A "formal standard" is something else, it usually refers to a more-or-less exact and complete _informal_ specification that is uniquely identified by its designation. The main difference is that in theory, you could check a formal specification for soundness using an automated theorem prover. Or you could automatically generate a compiler from it. An informal (but possibly exact) specification does not allow that, as it needs a human in the loop.

He has not acquired a fortune; the fortune has acquired him. -- Bion

Working...