Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Ordering of static destructors on exit
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ordering of static destructors on exit




On Aug 8, 2006, at 11:14 PM, Rob Cas wrote:

I was wondering if anybody can tell me precisely when the destructors
of static objects are called.

C++ doesn't not specify the order in which dtors are called. You cannot rely on this order as it can and has changed before. You likely need to restructure your code such that this is not an issue. What I've found to work best is to ensure that dtors of static objects do nothing nontrivial.


--
Steve Checkoway



Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Ordering of static destructors on exit (From: "Rob Cas" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.