Re: Fwd: Re: #25494 [Com]: array_merge allowing "false" as argument (silent when non-array is passed)

From: Date: Tue, 23 Sep 2003 15:44:29 +0000
Subject: Re: Fwd: Re: #25494 [Com]: array_merge allowing "false" as argument (silent when non-array is passed)
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-4553@lists.php.net to get a copy of this message
Is this fix really causing this much grief? Throwing an E_NOTICE isn't a BC break. It still works as before, it just throws the E_NOTICEs now. This was meant to be a bridge to the behaviour used in PHP 5, which, like other array_*() functions, doesn't work on non-arrays at all. (Although that fix for PHP 5 is debatable, I suppose.) The function is called array_merge(), not null_merge() or string_merge(). The change was to make it act more like other array functions, like array_intersect() or array_sum(), which also check parameters for arrays. What's the consensus? Keep the change or revert? Personally, I think it's more consistent if it acts like the other array functions, but if it's causing a lot of headaches... Just a thought -- perhaps keep it in for the first 4.3.4 RC and gauge the reaction and go from there? J Jan Schneider wrote: > Hi, > > the recent change to array_merge that now checks for IS_ARRAY breaks BC > IMO. At least I know get a lot of E_NOTICEs everywhere. >

« previous php.internals (#4553) next »