#36669 [Opn->Bgs]: php 5 foreach() bug

From: Date: Thu, 09 Mar 2006 13:49:55 +0000
Subject: #36669 [Opn->Bgs]: php 5 foreach() bug
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-94092@lists.php.net to get a copy of this message
ID: 36669 Updated by: tony2001@php.net Reported By: peterpub1 at bivol dot net -Status: Open +Status: Bogus Bug Type: Variables related Operating System: CENT OS PHP Version: 5.1.2 New Comment: Do not file bugs when you have Zend extensions (zend_extension=) loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache, APC, Xdebug and ionCube loader. These extensions often modify engine behavior which is not related to PHP itself. Not PHP problem. Previous Comments: ------------------------------------------------------------------------ [2006-03-09 14:38:09] peterpub1 at bivol dot net Description: ------------ OS: CENT OS PHP VERSION: 5.05 Zend Optimizer: 2.6.2 This line: foreach($GLOBALS as $key => $val){ ..... } When this piece of code is optimized/compiled with Zend produces this error: "Warning: Invalid argument supplied for foreach() in... " Not optimized works without any problems ? another bug like php 4.3.10 ? Reproduce code: --------------- foreach($GLOBALS as $key => $val){ ..... } Expected result: ---------------- see values Actual result: -------------- "Warning: Invalid argument supplied for foreach() in... " ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=36669&edit=1

« previous php.bugs (#94092) next »