Bug #62769 [Com]: Inconsistent notice reporting using []
| From: | julien at palard dot fr | Date: | Wed, 28 May 2014 09:37:57 +0000 |
| Subject: | Bug #62769 [Com]: Inconsistent notice reporting using [] | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-185946@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=62769&edit=1
ID: 62769
Comment by: julien at palard dot fr
Reported by: julien at palard dot fr
Summary: Inconsistent notice reporting using []
Status: Open
Type: Bug
Package: *General Issues
PHP Version: 5.4.5
Block user comment: N
Private report: N
New Comment:
Also :
$ php -r 'error_reporting(-1); $foo = 0; var_dump($foo["foo"]);'
NULL
Seems not right, I'd rather prefer to get, at least, a NOTICE here.
Previous Comments:
------------------------------------------------------------------------
[2014-04-28 21:28:25] requinix@php.net
Related To: Bug #67149
------------------------------------------------------------------------
[2013-08-20 08:33:54] requinix@php.net
Related To: Bug #65484
------------------------------------------------------------------------
[2012-09-04 17:54:36] ajf at ajf dot me
Well, according to someone in internals whose name I forgot, NULL[$anything] is
implicitly NULL. Which I think is rather absurd, personally. I don't see why it's
not an error.
------------------------------------------------------------------------
[2012-08-08 07:10:11] julien at palard dot fr
laruence@php.net : Nice for const array dereference :-)
But what about the point of the ticket :
$foo = NULL;
echo $foo["bar"];
that fails silently ?
------------------------------------------------------------------------
[2012-08-08 02:36:41] laruence@php.net
const array dereference is only in trunk
------------------------------------------------------------------------
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
https://bugs.php.net/bug.php?id=62769
--
Edit this bug report at https://bugs.php.net/bug.php?id=62769&edit=1