Re: R: [PHP-GENERAL] syntax error?

From: Date: Wed, 21 Jun 2000 14:40:10 +0000
Subject: Re: R: [PHP-GENERAL] syntax error?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-2496@lists.php.net to get a copy of this message
Hi Roberto! On Wed, 21 Jun 2000, Roberto Sartor wrote: > In C syntax would be: > $a = (isset($b) ? &$c : &$d); > > Your "$a = (isset($b)) ? &$c : &$d;" means: > assign $a value isset($b). All after "?" is considered trash hmm, assignement is evaluated right-to-left, and `?:' operator is the right one. So first, it will evaluate ?:' and assign that to the left operand of =' and (isset(b)) is the first operand of `?:' so we won't have any trash there :) bye -- teodor

« previous php.general (#2496) next »