Re: tableView - message sent to deallocated instance
Re: tableView - message sent to deallocated instance
- Subject: Re: tableView - message sent to deallocated instance
- From: Pax <email@hidden>
- Date: Wed, 26 Feb 2014 21:22:15 +0000
The thing that I love about this site is that it always encourages developers to be better, to do better. Awesome stuff. I also like the phrase 'programming by chance'!
Your spidey sense is oddly aligned with mine - that's the first thing that I thought and the first thing that I fixed (initially, there was a bug where the table view delegate wasn't being nilled out). Sadly, it didn't make one iota of difference to the problem.
I'll be reinvestigating… Eventually. Right now there are other problems to fix, other bugs to solve - and if this problem has gone away I can live with it, even if I'm not entirely happy with it.
On 26 Feb 2014, at 21:11, Kyle Sluder <email@hidden> wrote:
> On Wed, Feb 26, 2014, at 12:42 PM, Pax wrote:
>> Thanks for your help. The problem is now solved - although I'm still none
>> the wiser as to why the problem only manifested when the file was opened
>> and then the document closed before the file was closed. I'm kind of
>> curious to understand what was going on under the hood that might explain
>> this oddity - but I suppose I'll never know.
>
> You _can_ know. It's not that hard. And until you _do_ know, the bug
> isn't fixed.
>
>> The solution to the problem was to empty the array populating the table
>> and then reload the table before closing the document. It feels like an
>> oddly unnecessary extra step.
>
> That's not a solution. It's programming by chance.
>
> My spidey senses tell me that the crash happens because you forgot to
> nil out the table view's delegate in your window controller's -dealloc.
>
> --Kyle Sluder
_______________________________________________
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