|
Author |
Message |
Hertzsprung
WebHelper
Joined: 30 Jul 2002
Posts: 56
Location: UK
|
Posted:
Tue Mar 25, 2003 10:18 am (21 years, 1 month ago) |
|
What is the difference between new Foo() and &new Foo()?
I was having trouble with data initialised after object1 construction, passing object1 (by reference, or so I thought) to object2. Then object2 calls object1's method, which sees the instance data uninitialised |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Sun May 04, 2003 12:59 pm (20 years, 11 months ago) |
|
Sorry about the long reply - you've probably already found out, but never mind .
Here's what I found on the subject, after a somewhat painful search, since PHP's search engine (htdig if I'm not mistaken) ignores the & character:
http://www.php.net/manual/en/language.references.whatdo.php |
________________________________
|
|
|
|
SfCommand
Senior WebHelper
Joined: 10 Nov 2002
Posts: 143
Location: UK
|
Posted:
Sun May 04, 2003 4:15 pm (20 years, 11 months ago) |
|
|
|
|
Hertzsprung
WebHelper
Joined: 30 Jul 2002
Posts: 56
Location: UK
|
Posted:
Sat May 31, 2003 9:47 am (20 years, 10 months ago) |
|
Daniel wrote: | Sorry about the long reply - you've probably already found out, but never mind .
Here's what I found on the subject, after a somewhat painful search, since PHP's search engine (htdig if I'm not mistaken) ignores the & character:
http://www.php.net/manual/en/language.references.whatdo.php |
Hmm, okay. So all the time I'm not using =& , I'm wasting CPU time and memory making copies of objects all over the place? No wonder my code is so slow |
|
|
|
|
|
|
You cannot post new topics in this forum. You cannot reply to topics in this forum. You cannot edit your posts in this forum. You cannot delete your posts in this forum. You cannot vote in polls in this forum.
|
Page generation time: 0.24369 seconds :: 18 queries executed :: All Times are GMT
Powered by phpBB 2.0
© 2001, 2002 phpBB Group :: Based on an FI Theme
| |