#14066 [Sus->WFx]: Can't suppress warnigns on accessing invalid string offset

From: Date: Fri, 25 Apr 2003 16:08:00 +0000
Subject: #14066 [Sus->WFx]: Can't suppress warnigns on accessing invalid string offset
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-38379@lists.php.net to get a copy of this message
ID: 14066 Updated by: sniper@php.net Reported By: mfischer at guru dot josefine dot at -Status: Suspended +Status: Wont fix Bug Type: Scripting Engine problem Operating System: Any PHP Version: 4.0CVS-2001-11-15 New Comment: Since we now have this 'wont fix' status, let's use it. :) Previous Comments: ------------------------------------------------------------------------ [2002-03-03 17:47:39] derick@php.net It's an engine thing, and can really not be fixed. The accessing of the {3} is done after the END_SILENCE op at the CONCAT op. I'll mark it as suspended for now. ------------------------------------------------------------------------ [2002-03-03 17:35:33] mfischer@php.net I'm not satisfied with this answer :-) Why does it work with arrays but not with strings (and, bert, yeah I know they aren't the same). Just because "it's strings here" doesn't legitimate that a warnings is thrown. Using your suggestion is rather cumbersome. Is it an implemention issue? Can it be solve to be less long winded? "it is" a bug imho :) ------------------------------------------------------------------------ [2002-03-03 17:35:31] mfischer@php.net I'm not satisfied with this answer :-) Why does it work with arrays but not with strings (and, bert, yeah I know they aren't the same). Just because "it's strings here" doesn't legitimate that a warnings is thrown. Using your suggestion is rather cumbersome. Is it an implemention issue? Can it be solve to be less long winded? "it is" a bug imho :) ------------------------------------------------------------------------ [2002-03-03 17:28:03] derick@php.net It's not a bug, $foo{3}. "\n" is done before the @, so that displays the error. so I'm closing this, this works BTW: $foo = "foo"; echo @($foo{3}. "\n"); Derick ------------------------------------------------------------------------ [2001-12-02 17:06:21] mfischer@php.net One more, this change happened in Zend/zend_execute.c line 103. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/14066 -- Edit this bug report at http://bugs.php.net/?id=14066&edit=1

« previous php.bugs (#38379) next »