Re: Re: com php-src: Fix bug #67064 => Countable interface inconsistency

From: Date: Fri, 25 Jul 2014 09:54:15 +0000
Subject: Re: Re: com php-src: Fix bug #67064 => Countable interface inconsistency
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-76106@lists.php.net to get a copy of this message
On 23/07/2014 13:01, Dan Ackroyd wrote: > Regarding the change in behaviour, I think the patch > > https://bugs.php.net/patch-display.php?bug=67064&patch=bug67064-BC&revision=1402667581 > should definitely be applied. > > Currently the engine is doing magic stuff by modifying the parameters > that are passed to the function. i.e. you call count() with no > parameters and it arrives at the function with parameters. \o/ > > Even if that wasn't a BC break, having magic behaviour in a language > is very, very bad. I agree, that's why I wrote the tiny patch in the first place ;) IMHO, the functionality as it is now breaks the principle of least surprise. Cheers -- Matteo Beccati Development & Consulting - http://www.beccati.com/

« previous php.internals (#76106) next »