Re: [RFC] Class instances counter
| From: | Joe Watkins | Date: | Tue, 09 Apr 2013 00:29:16 +0000 |
| Subject: | Re: [RFC] Class instances counter | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-67006@lists.php.net to get a copy of this message | ||
On 04/08/2013 09:07 PM, Madara Uchiha wrote:
I'm with Morrison, I see no actual use for this. It's "cool", but what would you use it for? On Mon, Apr 8, 2013 at 10:47 PM, Levi Morrison <morrison.levi@gmail.com> wrote:I see some merit in the idea that during development of an application it could be useful to get a profile view of the object store, without affecting those objects or introducing new objects in order to provide that view. There are other run-time use cases, but for me, mostly development and debugging, without being intrusive or having any real impact on the application or object store.I see little value in having a function that tells me how many objects of any kind I have instantiated. Mostly, I see it as a way to help teach people about assignment of objects works in PHP:$a = new MyClass(); $b = $a; var_dump(get_object_count());And that's about the sum of how useful I think this is. If it were to be able to narrow it to a specific class then it *might* be a little more useful. -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php