• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Main window disappears. Sometimes.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Main window disappears. Sometimes.


  • Subject: Re: Main window disappears. Sometimes.
  • From: mmalc crawford <email@hidden>
  • Date: Mon, 02 Jun 2008 11:40:13 -0700


On Jun 2, 2008, at 10:50 AM, Bill Bumgarner wrote:

If your window is sometimes disappearing under GC -- is sometimes being collected prior to when you think it should be -- that means that the collector doesn't believe that the window object is being used by your application. To the collector, being visible doesn't count as "in use".
In GC, "in use" is defined entirely by whether or not you have a reference to an object. A pointer to the object somewhere in scanned memory (of which, any Objective-C object's data will be "scanned memory").


I wonder if this might be misleading.
Simply because you have a (strong) reference to an object does not *necessarily* mean that it won't be treated as garbage.


Several objects may have strong references to each other (creating what in a managed memory environment would be a retain cycle), but if none of them is a root object, and none of them can be reached via strong references from a root object, then they will all be treated as garbage -- see the "F-G-H" example at <http://developer.apple.com/documentation/Cocoa/Conceptual/GarbageCollection/Articles/gcEssentials.html >.

mmalc

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Main window disappears. Sometimes.
      • From: Bill Bumgarner <email@hidden>
References: 
 >Main window disappears. Sometimes. (From: Francis Perea <email@hidden>)
 >Re: Main window disappears. Sometimes. (From: Graham Cox <email@hidden>)
 >Re: Main window disappears. Sometimes. (From: Francis Perea <email@hidden>)
 >Re: Main window disappears. Sometimes. (From: Michael Vannorsdel <email@hidden>)
 >Re: Main window disappears. Sometimes. (From: Bill Bumgarner <email@hidden>)

  • Prev by Date: Re: Leopard (10.5+): Any Upper-Level (Cocoa) access to Mail?
  • Next by Date: [Moderator] Re: Leopard (10.5+): Any Upper-Level (Cocoa) access to Mail?
  • Previous by thread: Re: Main window disappears. Sometimes.
  • Next by thread: Re: Main window disappears. Sometimes.
  • Index(es):
    • Date
    • Thread