Re: bug when using foreach with references?

From: Date: Thu, 22 Oct 2009 17:14:50 +0000
Subject: Re: bug when using foreach with references?
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to internals+get-45874@lists.php.net to get a copy of this message
It would be arbitrarily breaking an explicit reference. I know I have code lying around that relies on multiple loops cleaning up a big complicated multi-level array. I do ugly things with references into that array and it would completely break if PHP magically deleted my references whether they are in the iterator or elsewhere. This has been this way for 6+ years and it is well documented on the http://php.net/foreach page. (see the big red warning box) -Rasmus
Fair enough. Thanks for examining it again with me. Best, Richard

« previous php.internals (#45874) next »