|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-02-28 15:59 UTC] iliaa@php.net
-Status: Open
+Status: Bogus
[2011-02-28 15:59 UTC] iliaa@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Dec 18 17:00:02 2025 UTC |
Description: ------------ If you use array_merge_recursive to join arrays which have different numeric keys, free keys are nor used if the later array has a key which is below the first/highest key. Test script: --------------- var_dump(array_merge_recursive( array("a" => array(5 => "7")), array("a" => array(3 => "8")) ));' Expected result: ---------------- array(1) { ["a"]=> array(2) { [3]=> string(1) "8" [5]=> string(1) "7" } } Actual result: -------------- array(1) { ["a"]=> array(2) { [5]=> string(1) "7" [6]=> string(1) "8" } }