On 29/04/11 2:10 AM, Alain Williams wrote:
On Fri, Apr 29, 2011 at 01:58:02AM +1000, Ben Schmidt wrote:
If PHP were compiled, not interpreted, i.e. less dynamic, there could be
some benefits, as compile-time optimisations could perhaps be built in, and
validations skipped if they were provably unnecessary. But that's not going
to happen any time soon, as far as I'm aware.
It has already happened:
https://github.com/facebook/hiphop-php/wiki/
It might also be useful for reflection.
*Hastily retracts comment.*
That is very cool. I should give it a try.
I also see the value of such type checking for such a use case, obviously.
I guess there's a reason for it after all.
I'd still like to see something neat to handle more than just named classes,
though, e.g. scalars, and things like "false on error" for return values.
Ben.
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php