• 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: Block until block is called
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Block until block is called


  • Subject: Re: Block until block is called
  • From: Andreas Grosam <email@hidden>
  • Date: Sat, 27 Aug 2011 09:13:18 +0200

On Aug 27, 2011, at 7:36 AM, Brian Norh wrote:

> On Sat, Aug 27, 2011 at 7:07 AM, Glenn L. Austin <email@hidden> wrote:
>
>> Um, why would you want to (or need to) do that?
>
> It's often not necessary at all but I've found a very rare case where
> if the API is called from within another block it sometimes makes
> sense to do that, at least for now until the API is updated.
>
> Brian

Uhm, if the reason for this rare case is to avoid race conditions, you should rethink your design  ;)
Your design is OK if you have no race conditions, at any legal usage of your API. Of course, you could say "This API is not thread safe and can be used only from the main thread." However, this would be a rather harsh limitation._______________________________________________

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

  • Follow-Ups:
    • Re: Block until block is called
      • From: Brian Norh <email@hidden>
References: 
 >Block until block is called (From: Brian Norh <email@hidden>)
 >Re: Block until block is called (From: "Glenn L. Austin" <email@hidden>)
 >Re: Block until block is called (From: Brian Norh <email@hidden>)

  • Prev by Date: Re: Block until block is called
  • Next by Date: Re: NSWindow setFrame:display: ceiling behavior?
  • Previous by thread: Re: Block until block is called
  • Next by thread: Re: Block until block is called
  • Index(es):
    • Date
    • Thread