• 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: "Sean McBride" <email@hidden>
  • Date: Tue, 3 Jun 2008 11:28:58 -0400
  • Organization: Rogue Research

On 6/2/08 7:47 PM, William Bumgarner said:

>So, no, I don't buy for a moment that non-GC is simpler than GC.   The
>case the OP had is an edge case and, with a bit of thought, becomes
>fairly obvious what has gone wrong;   the object is being collected
>because nothing is referring to it.  Note that the application did not
>crash, as would be typical in the non-GC case.   Given that the OP had
>to be manually loading a NIB in the first place in a context that is
>both not the main NIB file and not in a document based application, said
>NIB loading pattern is definitely moving outside of the realm of rank
>beginner.
>
> *SNIP*
>
>Reference counting based development is an anachronism within Cocoa
>programming.   A very important, very well supported, anachronism.
>Reference counting will be around for a long long time to come,
>certainly, but there is absolutely no reason to use reference counted
>based Cocoa development save for legacy reasons and a handful of project
>types that really really need the absolute and total determinism of a
>reference counted system (of which, "when -dealloc is executed" should
>not be a consideration).    There are actually a number of very solid
>performance and maintainability reasons to avoid retain/release/autorelease.

I prefer GC too, but, for beginners especially, one problem with GC is
tools support and documentation.

For example, the excellent TN2124 "Mac OS X Debugging Magic" does not
even contain the word "garbage".  Browse through NSDebug.h: not a word
there either.  Malloc Debug.app spews an unhelpful error when used with
GC apps (it doesn't support them, though happily Instruments does).

OTOH, the ref counting model has tonnes of helpful debugging aids and docs.

--
____________________________________________________________
Sean McBride, B. Eng                 email@hidden
Rogue Research                        www.rogue-research.com
Mac Software Developer              Montréal, Québec, Canada

_______________________________________________

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

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>)
 >Re: Main window disappears. Sometimes. (From: Paul Sargent <email@hidden>)
 >Re: Main window disappears. Sometimes. (From: William Bumgarner <email@hidden>)

  • Prev by Date: Re: Copying NSTextStorage
  • Next by Date: Re: trying to glue a cocoa ui to a pthread application / subclassing nsview
  • Previous by thread: Re: Main window disappears. Sometimes.
  • Next by thread: Re: Main window disappears. Sometimes.
  • Index(es):
    • Date
    • Thread