Re: cleaning up the functions - any volunteers?

From: Date: Sun, 22 Jun 2008 21:32:39 +0000
Subject: Re: cleaning up the functions - any volunteers?
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to internals+get-38521@lists.php.net to get a copy of this message
On 22.06.2008, at 23:21, Stanislav Malyshev wrote:
Hi!
is this in any way related to the parameter parsing API change that caused the BC break in array_merge() back in PHP 5.0? If so then I would
I don't really remember about array_merge in detail, but this change shouldn't (I know, famous last words :) create any BC break unless you rely on weird stuff like array-to-string implicit conversion (which you really really shouldn't touch with a ten foot pole anyway).
The break in array_merge() was that previously it would cast the parameters to an array. As such a popular use case before the parameter parsing change was the following: $foo = null; $bar = array_merge($foo, $array); Since 5.0 this would lead to $bar being false and not $array. While it could be argued that the user should do an explicit cast himself, it was still a clear BC issue that caused a lot of issues for developers. regards, Lukas Kahwe Smith mls@pooteeweet.org

« previous php.internals (#38521) next »