On Sun, Sep 14, 2014 at 3:22 PM, Derick Rethans <der...@php.net> wrote: > We can either have casting where: > > function bar(int $foo) { } > bar("42"); > > Means the same as: > > function bar($foo) { } > bar((int) "42"); > > Or we can have it as a strict cast, or we can have it like it currently > (ie, not at all). I can live with those three options, but not an > option where casting/checking does something different again. >
I totally agree with this. I can understand any of the following: 1) function f(int $a) { } == f( (int) $a); -- with NO notices 2) function f(int $a) {} means $a must be exactly type int -- or recoverable error is thrown 3) current behavior (no scalar type hints) But a new set of rules that require a 23x7 table to describe what's going on ... not a big fan. -- Matthew Leverton -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php