php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #25996 Assignment by reference suppress index error
Submitted: 2003-10-26 21:33 UTC Modified: 2004-05-01 09:39 UTC
Votes:2
Avg. Score:3.0 ± 2.0
Reproduced:1 of 2 (50.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: hongnk at hotmail dot com Assigned:
Status: Not a bug Package: Scripting Engine problem
PHP Version: 5CVS, 4CVS (2004-03-15) OS: *
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: hongnk at hotmail dot com
New email:
PHP Version: OS:

 

 [2003-10-26 21:33 UTC] hongnk at hotmail dot com
Description:
------------
Accessing array with uninitialized index will normally trigger error:

$a=array();
$b=$a['unknown']; => undefined index error

but if I assign by reference:

$b=&$a['unknown'];

then PHP no longer throw error. (The same goes for assigning undefined property to an object.)

This makes it difficult to debug scripts.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-10-29 14:13 UTC] moriyoshi@php.net
Related to bug #26030
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue May 21 11:01:34 2024 UTC