Re: [PEPr] +1 for Networking::Net_HL7
| From: | Daniel Convissor | Date: | Sat, 03 Jul 2004 16:59:59 +0000 |
| Subject: | Re: [PEPr] +1 for Networking::Net_HL7 | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-31527@lists.php.net to get a copy of this message | ||
On Sat, Jul 03, 2004 at 01:49:30AM -0700, Justin Patrin wrote:
> > Arnaud Limbourg (http://pear.php.net/user/arnaud) has voted +1 on the proposal for
> > Networking::Net_HL7.
> >
> > return new Net_HL7_Response($data);
>
> It's my understanding that this has been fixed in PHP5. It was a bug.
Returning by reference implies that you are returning a variable. When
you return an object like that, you're not technically returning a
variable. So, it wasn't a bug. PHP 4 was kind enough to allow it, though
it caused memory corruption. PHP 5 was smart enough to say, "no way!"
Well, the memor corruption issue is reported to be fixed and PHP 5 allows
it. At the same time, I think taking advantage of this feature isn't the
greatest idea due to the potential of the behavior changing in the long
term.
--Dan
--
T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y
data intensive web and database programming
http://www.AnalysisAndSolutions.com/
4015 7th Ave #4, Brooklyn NY 11232 v: 718-854-0335 f: 718-854-0409