• 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: resetting ivars safely
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: resetting ivars safely


  • Subject: Re: resetting ivars safely
  • From: Uli Kusterer <email@hidden>
  • Date: Fri, 14 Sep 2007 10:22:20 +0200

On 13.09.2007, at 18:15, Daniel Child wrote:
This option seems to work, and the "word parser" (kind of a misnomer) now works indefinitely without crashing.

If it's a misnomer, rename it. You'll be writing your code once, but you'll be re-reading it over and over again during debugging. Trust me, you'll want your code to be as readable as possible. Anything else will just make you eventually throw away solid and tested code because it's become too un-manageable to fix that one tiny bug. And that's just wasteful.



I can go through an indefinite number of cycles of "get candidates" "reset" without any hiccups.

Still, check your retains and releases. If you got a BAD_ACCESS, that means you had an object that went out of scope where you didn't expect it to. Such memory bugs are hard to track down, because disposed memory doesn't get cleared, so the object may look completely valid a moment after it's been released. Your new code probably just caused things to move around in RAM in a way that the released objects didn't get overwritten as quickly. The issue has just been hidden, but it's unlikely that it is actually gone.


Cheers,
-- M. Uli Kusterer
http://www.zathras.de

_______________________________________________

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: 
 >resetting ivars safely (From: Daniel Child <email@hidden>)
 >Re: resetting ivars safely (From: Uli Kusterer <email@hidden>)

  • Prev by Date: Re: Pages document
  • Next by Date: NSWindow contentView buffer
  • Previous by thread: Re: resetting ivars safely
  • Next by thread: Fwd: resetting ivars safely
  • Index(es):
    • Date
    • Thread