Bug #14066 Updated: Can't suppress warnigns on accessing invalid string offset

From: Date: Sun, 02 Dec 2001 22:01:01 +0000
Subject: Bug #14066 Updated: Can't suppress warnigns on accessing invalid string offset
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-72283@lists.php.net to get a copy of this message
ID: 14066 Updated by: phanto Reported By: mfischer@guru.josefine.at Status: Open Bug Type: Scripting Engine problem Operating System: Any PHP Version: 4.0CVS-2001-11-15 New Comment: 'isset($foo[0])' issues a warning too if $foo is an emtpy string. Previous Comments: ------------------------------------------------------------------------ [2001-11-15 02:33:34] mfischer@guru.josefine.at When setting error_reporting(E_ALL) the following occurs: <? error_reporting(E_ALL); $foo = array(); echo $foo[0] . "\n"; // <-- warning $foo = array(); echo @$foo[0]. "\n"; // <-- no warning $foo = "foo"; echo $foo{3} . "\n"; // <-- warning $foo = "foo"; echo @$foo{3}. "\n"; // <-- still warning ?> The last line should not emit a warning. ------------------------------------------------------------------------ Edit this bug report at http://bugs.php.net/?id=14066&edit=1

« previous php.dev (#72283) next »