Re: New destructors implementation

From: Date: Mon, 09 Feb 2004 14:04:54 +0000
Subject: Re: New destructors implementation
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-7661@lists.php.net to get a copy of this message
At 01:36 PM 2/9/2004 +0000, Stephane Drouard wrote:
== Quote from Zeev Suraski (zeev@zend.com)'s article They're not locked to 1, and nothing in a symbol table will ever be with a refcount of less than 1... But generally, all global variables (or for that matter, all variables period) have a refcount of 1, unless you do something 'special'. Right. So if a global variable "father" owns a reference to another global variable "child", I assume "child"'s refcount is higher than "father"'s one, let's say 2 for "child" ($GLOBALS + "father") and 1 for "father" ($GLOBALS), assuming they are not referenced elsewhere. So why PHP can't guaranty that "father"'s destructor is called before "child"'s one?
He doesn't necessarily own a reference but tries to access it in the destructor. Andi

« previous php.internals (#7661) next »