#22088 [NEW]: array_shift() and the last index of the array

From: Date: Thu, 06 Feb 2003 09:43:21 +0000
Subject: #22088 [NEW]: array_shift() and the last index of the array
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-32273@lists.php.net to get a copy of this message
From: audrius@vpu.lt Operating system: Linux, Windows PHP version: 4.3.0 PHP Bug Type: Arrays related Bug description: array_shift() and the last index of the array $m=array('a','b'); $last = array_shift ($m); $m[]='c';//or array_push ($m,'c'); print_r($m); in 4.3.0 output is: Array ( [0] => b [2] => c ) In previous php versions output was: Array ( [0] => b [1] => c ) As yuo see, index for element 'c' differs. -- Edit bug report at http://bugs.php.net/?id=22088&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=22088&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=22088&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=22088&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=22088&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=22088&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=22088&r=support Expected behavior: http://bugs.php.net/fix.php?id=22088&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=22088&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=22088&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=22088&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=22088&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=22088&r=dst IIS Stability: http://bugs.php.net/fix.php?id=22088&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=22088&r=gnused

« previous php.bugs (#32273) next »