#33319 [Opn->Bgs]: Cannot re-assign $this
| From: | derick@php.net | Date: | Sun, 12 Jun 2005 21:22:15 +0000 |
| Subject: | #33319 [Opn->Bgs]: Cannot re-assign $this | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-80202@lists.php.net to get a copy of this message | ||
ID: 33319
Updated by: derick@php.net
Reported By: sailormax at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: WinXP
PHP Version: 5.1.0b1
New Comment:
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
so don't assign it by reference...
Previous Comments:
------------------------------------------------------------------------
[2005-06-12 23:12:58] sailormax at gmail dot com
Description:
------------
class member function do not accept bind to any variable address of
$this. I do not want edit "$this"! I want work with it by another
variable!
(zend.ze1_compatibility_mode = On)
Reproduce code:
---------------
<?
class foo
{
function test($obj = '')
{
if ($obj == '') $obj =& $this;
}
}
?>
Expected result:
----------------
everything must be ok
Actual result:
--------------
Fatal error: Cannot re-assign $this in index.php on line 6
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=33319&edit=1