note 51964 added to language.references.whatdo

From: Date: Sun, 17 Apr 2005 09:05:47 +0000
Subject: note 51964 added to language.references.whatdo
Groups: php.notes 
Request: Send a blank email to php-notes+get-88102@lists.php.net to get a copy of this message
I ran into something when using an expanded version of the example of pbaltz at NO_SPAM dot cs dot NO_SPAM dot wisc dot edu below. This could be somewhat confusing although it is perfectly clear if you have read the manual carfully. It makes the fact that references always point to the content of a variable perfectly clear (at least to me). <?php $a = 1; $c = 2; $b =& $a; // $b points to 1 $a =& $c; // $a points now to 2, but $b still to 1; echo $a, " ", $b; // Output: 2 1 ?> ---- Manual Page -- http://www.php.net/manual/en/language.references.whatdo.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+51964 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+51964&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+51964&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+51964&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+51964&report=yes&reason=useless Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+51964&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+51964&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#88102) next »