On 22 Dec 2011, at 4:02 PM, Fritz Anderson wrote: > Maybe I have to have another look at that horrific little ARC dance. If > that's necessary, then I was wrong to declare the object-controller outlets > u_u, they should be strong, and I should then do the HLAD.
HLAD was harmful — passing the top-level objects to CFRelease() to relieve the "extra" retention resulted in an overrelease. So now what I'm doing is: - Declare the property holding the top-level object strong. - Manually nil-out the property at windowWillClose: time. If I don't do this, the objects' references back to the NSDocument (they are NSControllers bound to model objects through the document) will produce a retain loop so the document will never be dealloced. This leads me to believe that a 10.6-targeted ARC application, running on 10.7, will _not_ see +1 retained top-level objects. Which leads me once again to wonder what happens on 10.6. Do the NSControllers get overretained? If so, is there a way to detect the different loading behavior and do an extra release accordingly? I'm beginning to sense ARC + Mac + NIBs + 10.6 is a corner case that wasn't fully thought out. — F _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com