• 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: Cleaning up a window with blocks
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cleaning up a window with blocks


  • Subject: Re: Cleaning up a window with blocks
  • From: Eric Gorr <email@hidden>
  • Date: Thu, 29 Sep 2011 16:35:45 -0400

Ya, thanks.

I spotted that almost immediately after I posted the message.

On Sep 29, 2011, at 4:22 PM, Ken Thomases wrote:

> On Sep 29, 2011, at 11:42 AM, Thomas Davie wrote:
>
>> A quick scan over the code says that your issue is that you're referring to theObserver inside theObserver, which, when the block is constructed, as not yet been assigned the result of addObserverForName:...
>
> You can fix that by declaring theObserver with the __block qualifier.
>
> Cheers,
> Ken
>

_______________________________________________

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: 
 >Cleaning up a window with blocks (From: Eric Gorr <email@hidden>)
 >Re: Cleaning up a window with blocks (From: Thomas Davie <email@hidden>)
 >Re: Cleaning up a window with blocks (From: Ken Thomases <email@hidden>)

  • Prev by Date: Re: Cleaning up a window with blocks
  • Next by Date: Question about SMJobBless
  • Previous by thread: Re: Cleaning up a window with blocks
  • Next by thread: Question about SMJobBless
  • Index(es):
    • Date
    • Thread