Re: Return value efficiency question
| From: | messju mohr | Date: | Wed, 10 Mar 2004 13:56:36 +0000 |
| Subject: | Re: Return value efficiency question | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-180020@lists.php.net to get a copy of this message | ||
On Wed, Mar 10, 2004 at 04:48:06PM +0300, Burhan Khalid wrote:
> Kelly Hallman wrote:
> >Consider this method:
> >
> > function xyz() {
> > return $this->data = unserialize($this->serial); }
> >
>
> Maybe I'm just being stupid, but wouldn't that simply return true if the
> assignment was successful, and false otherwise?
no, the return-value of the assignment is the right side of the
assignment (the value that was assigned).
> [ trimmed ]
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php