On 29 October 2015 at 12:48, Pedro Cordeiro <pedronar...@gmail.com> wrote: > Like I said in a previous post, there is no need to forbid using a void > function return value. > > Throwing an E_NOTICE would be sufficient to inform the developer he's doing > something weird
To me, that is not really different from forbidding it as it is good practice to turn all notices into errors, and it is not a good idea to blindly start suppressing errors. e.g. this code: $fn = getCallbackFunction(); logResult($fn()); would need error suppression as it's not possible to know whether the function is going to be 'void' or not. But that suppression could also hide actual errors. cheers Dan -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php