Fixing strange foreach behavior.
| From: | Yasuo Ohgaki | Date: | Fri, 16 Jan 2015 08:40:49 +0000 |
| Subject: | Fixing strange foreach behavior. | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-80626@lists.php.net to get a copy of this message | ||
Hi all,
Take a look at
http://3v4l.org/HbVnd
foreach should not affect internal(zval) array position, but it does.
I'm not sure why foreach works this way, but HHVM behavior is
reasonable. IMHO.
PHP 7 would be perfect opportunity fix this behavior.
Any comments?
Regards,
--
Yasuo Ohgaki
yohgaki@ohgaki.net