note 82956 added to language.oop5.overloading

From: Date: Sat, 03 May 2008 14:46:34 +0000
Subject: note 82956 added to language.oop5.overloading
Groups: php.notes 
Request: Send a blank email to php-notes+get-139023@lists.php.net to get a copy of this message
@Hayley Watson $a = $b = $c is not the same as $a = ($b = $c). In the second example, $a will be boolean true or false depending on whether $c has a value that is considered to be a loose true or false. <? $c = 1; $a = ($b = $c); // $a === true $c = 0; $a = ($b = $c); // $a === false $c = "blah"; $a = ($b = $c); // $a === true $c = ""; $a = ($b = $c); // $a === false ?> ---- Server IP: 64.71.164.2 Probable Submitter: 71.35.194.94 ---- Manual Page -- http://www.php.net/manual/en/language.oop5.overloading.php Edit -- https://master.php.net/note/edit/82956 Del: integrated -- https://master.php.net/note/delete/82956/integrated Del: useless -- https://master.php.net/note/delete/82956/useless Del: bad code -- https://master.php.net/note/delete/82956/bad+code Del: spam -- https://master.php.net/note/delete/82956/spam Del: non-english -- https://master.php.net/note/delete/82956/non-english Del: in docs -- https://master.php.net/note/delete/82956/in+docs Del: other reasons-- https://master.php.net/note/delete/82956 Reject -- https://master.php.net/note/reject/82956 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#139023) next »