Re: Upgrade
| From: | Nathan Nobbe | Date: | Fri, 21 Sep 2007 17:21:56 +0000 |
| Subject: | Re: Upgrade | ||
| References: | 1 2 3 4 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-262344@lists.php.net to get a copy of this message | ||
On 9/21/07, Robert Cummings <robert@interjinn.com> wrote:
>
> Ps. I used references so PHP4 wouldn't create copies at every
> function call :)
i noticed the previously posted php4 code was doing a lot of copy
operations.
perhaps thats the only reason the code is actually working under 4 and the
clone keyword needed to be used in 5 (didnt look into it too much tho).
i always use the =& construct when assigning object references in php4.
this is another one of the sore spots i have for php4. the reason being
php4
requires developers to use the =& construct so that a copy is not created.
i like to think the people i work w/ are competent, but less face it, in
large systems
w/ lots of developers, its hard to ensure =& is always being used.
in fact, in php4 singletons break if =& is not used. that makes singleton
in php4
very delicate.
-nathan