Re: Missing __toString() part
| From: | Andi Gutmans | Date: | Sun, 04 Jun 2006 16:11:20 +0000 |
| Subject: | Re: Missing __toString() part | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-23941@lists.php.net to get a copy of this message | ||
At 09:05 AM 6/4/2006, Derick Rethans wrote:
On Sun, 4 Jun 2006, Andi Gutmans wrote: Again, I don't think we should have a hash but a unique id which can be used as an array key and in other things. Difference. Hash implies that it's not unique, I'm talking about unique. Instead of all those hacky ways to come up with IDs, why don't se simply change the engine not to reuse those IDs in the first place? Seems to solve quite a few problems.Because the idea is that each extension can control its own object storage if needed. If it gets a centralized id with an arbitrary limit (say 32bit) then they'd all have to use hashes for the storage instead of arrays. It's actually a beneficial thing that we decoupled the extensions. There is no reason why a string key such as I suggested, wouldn't solve your problems of lack of id... Andi