|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-01-21 20:46 UTC] derick@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 12:00:01 2025 UTC |
Description: ------------ This creates a need to define variables before being used which is opposite of PHP's original behavior and spirit. This strange array_merge behavior is one step closer to making PHP a strongly typed language if the function behaves differently depending on whether or not aruments are defined and empty or not defined at all. Reproduce code: --------------- $array2 = array('a'); $empty_var = array_merge($array1,$array2); Expected result: ---------------- $empty_var should be an array with the same contents as array2. Actual result: -------------- $empty_var contains no data at all. This is different from PHP4 behavior with no benefits.