Hello Stanislav,

Thursday, November 27, 2003, 3:32:25 PM, you wrote:

MB>>> It respects the refcoutning while destructing the zvals.

> I don't exacetly understand _how_ it respects them so that this solves the
> circular dependency problem. In fact, in the patch in the URL you have 
> sent I don't even see one call to destructor. Also, does you patch take 
> into account the fact that a number of zvals can refer to the same object?

When a zval is an object and it gets freed the destructor is called.

MB>>> Controlling life time of objects and hence you could also control
MB>>> lifetime of resources if you use php5 new database systems which use
MB>>> objects natively or if you use wrapper objects. So with destructors
MB>>> you can free them as soon as possible (automagically) without any
MB>>> further time consumpting tests. So you will also get lower memory

> I don't see how you can do that. Only place when you don't have to call 
> dtor manually and can be sure the object is destroyed is the end of the 
> request. But by the end of the request all resources are freed anyway, so 
> you don't need dtors to free them.

Well i can test my scripts - and i do understand refcounting and php. So at
least an expirienced programmer can take advantage.



-- 
Best regards,
 Marcus                            mailto:[EMAIL PROTECTED]

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to