Re[2]: [SMARTY-DEV] mixing of asign() and assign_by_ref() overwrites external vars

From: Date: Mon, 07 Jun 2004 21:53:26 +0000
Subject: Re[2]: [SMARTY-DEV] mixing of asign() and assign_by_ref() overwrites external vars
References: 1 2  Groups: php.smarty.dev 
Request: Send a blank email to php-smarty-dev+get-2408@lists.php.net to get a copy of this message
B> The whole point of assigning-by-reference is that you are B> aliasing the variable as opposed to making a copy. When you B> assign $test_2 = $test, even though you don't do it B> by-reference, you are making a copy of an object that contains B> references. When you alter the reference (even in the copy), B> you necessarily alter the original var. This is the way PHP B> works and I don't think it implies any problems with the B> Smarty semantics. I still don't understand why don't you want to appli little patch which was attached above. It is fully transparent, back-compatible and add new feautures (including fix of unsuspected behavour with assign after assign_by_ref). -- Best regards, Dmitry Koteroff.

« previous php.smarty.dev (#2408) next »