note 15490 deleted from language.references.return by sniper

From: Date: Tue, 30 Sep 2003 01:25:44 +0000
Subject: note 15490 deleted from language.references.return by sniper
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-57351@lists.php.net to get a copy of this message
Note Submitter: giorgio.galloNOSPAM@NOSPAMdedalomedia.it ---- I got REAL troubles returning references from class methods (i did not try with ordinary functions): At first all seemed to work well, but, while my project was growing bigger (i.e. started to instantiate more and more objects), the whole memory mapping of PHP 4.0.5 seemed to fail. Lines like theese: function foo($a){}; $b = "something"; foo("now it is something else"); echo($b); outputted: now it is something else I solved (walked around) those problems by returning BY VALUE from all methods. Hoping to be useful, Giorgio Gallo

« previous php.notes (#57351) next »