Bug #12692: The current() function does not return references

From: Date: Fri, 10 Aug 2001 17:21:25 +0000
Subject: Bug #12692: The current() function does not return references
Groups: php.dev 
Request: Send a blank email to php-dev+get-62858@lists.php.net to get a copy of this message
From: metz@studenten.net Operating system: Linux 2.4.2 PHP version: 4.0.6 PHP Bug Type: Arrays related Bug description: The current() function does not return references When filling an array with reference to objects the current() function does not return the reference to the object but a copy of the object. i.e. $ref = &current($some_array); returns a copy work around: $ref = &$some_array[key($some_array)]; returns the reference Is this a bug or a difference in implementation? -- Edit bug report at: http://bugs.php.net/?id=12692&edit=1

« previous php.dev (#62858) next »