Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:10068 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 28995 invoked by uid 1010); 24 May 2004 14:37:29 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 28949 invoked from network); 24 May 2004 14:37:29 -0000 Received: from unknown (HELO basiczlager.backendmedia.com) (195.75.116.242) by pb1.pair.com with SMTP; 24 May 2004 14:37:29 -0000 Received: from localhost (localhost [127.0.0.1]) by basiczlager.backendmedia.com (Postfix) with ESMTP id BEBAB82DB3; Mon, 24 May 2004 16:37:35 +0200 (CEST) Received: from basiczlager.backendmedia.com ([127.0.0.1]) by localhost (basiczlager [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 16704-05; Mon, 24 May 2004 16:37:30 +0200 (CEST) Received: from [192.168.0.77] (port-212-202-169-220.dynamic.qsc.de [212.202.169.220]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) by basiczlager.backendmedia.com (Postfix) with ESMTP id A6BDF82D59; Mon, 24 May 2004 16:37:29 +0200 (CEST) Message-ID: <40B20889.3080909@backendmedia.com> Date: Mon, 24 May 2004 16:36:57 +0200 Organization: BackendMedia GbR User-Agent: Mozilla Thunderbird 0.6 (Windows/20040502) X-Accept-Language: en MIME-Version: 1.0 To: Christian Schneider Cc: Adam Maccabee Trachtenberg , Jason Garber , internals@lists.php.net References: <5.1.0.14.0.20040523174015.02197460@mail.ionzoft.com> <40B1EAD7.1020800@cschneid.com> <40B207C0.5050402@cschneid.com> In-Reply-To: <40B207C0.5050402@cschneid.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by somedaemon at backendmedia.com Subject: Re: [PHP-DEV] Re: Destructors From: smith@backendmedia.com (Lukas Smith) Christian Schneider wrote: > Adam Maccabee Trachtenberg wrote: > >> That's not guaranteed to work. PHP 5 does not guarantee that object >> destructors will be called in any particular order or that the order >> will remain constant from one invocation to another. > > > Ok, I was under the impression that PHP won't call any destructors of > objects still in use but from your comment I guess it does two passes: > First collect a list of objects to destruct (which will be everything at > the end of the script) and then call all the destructors (in random order). unless you manually unset the objects in the order in which you want them to be destructed. regards, Lukas Smith