On Tue, 27 Apr 2004, Curt Zirzow wrote: > > I can't seem to find any discussion on this BC issue, so forgive me if > this has already been discussed. > > Given the following; > > $a = 'a string'; > > /* E_ERROR Cannot use string offset as an array */ > echo is_array($a['bar']['baz']); > > /* non error resolution */ > echo isset($a['bar']['baz']) && is_array($a['bar']['baz']); > > > I'm not sure, but the patch below does seem to make the E_ERROR > get demoted to a E_WARNING, thus fixing it so execution simply doesn't > stop when a string is referenced improperly. Or is it a *must* that php > needs to stop in this case?
I see no reason why PHP shouldn't stop in this case. You're definitely doing something wrong to create that E_ERROR. Derick -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php