At 08:28 28/05/2010, Tjerk Anne Meesters wrote:
On the other hand, auto-casting used to be my favourite until I
glanced over the conversion table; it's not just regular casting, it
has different rules. I wouldn't want to be the one going over that
table when writing code against a certain API, I should only need to
see the documentation.

Tjerk,

I think you have a nice idea about E_STRICT, except it makes much more sense with auto-conversion. That is - in case of 'fail' - we'd still convert, and emit E_STRICT (or E_NOTICE). That means that the API developer will always get the type he expects, while the user will be guided in the right direction in a friendly PHPish manner. The conversion table is up for discussion, BTW. If most people prefer that it's more similar to PHP's existing auto-conversion rules (that appears to be the case) we can certainly do that.

Zeev

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to