Hi Pavel, 

> On 11 Feb 2015, at 07:41, Pavel Kouřil <pajou...@gmail.com> wrote:
> 
> Also, I realized one thing why I think the strict version is a bad
> idea for PHP (in the state PHP is now - in an ideal world I would love
> to have nothing but strongly typed PHP, but that's offtopic) - PHP has
> many functions that return multiple types, so you cannot do foo(bar())
> if bar() has multiple return types. :(

You can’t do it with weak types either. Functions with multiple return type 
usually do so in order to use one type for success, and another return type on 
failure. In weak typing mode, PHP would just mangle the error value (like 
FALSE).

--
Andrea Faulds
http://ajf.me/





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

Reply via email to