Re: CFRunLoopRef to NSRunLoop: how?
Re: CFRunLoopRef to NSRunLoop: how?
- Subject: Re: CFRunLoopRef to NSRunLoop: how?
- From: Ken Thomases <email@hidden>
- Date: Sat, 22 Nov 2014 00:52:58 -0600
On Nov 22, 2014, at 12:43 AM, ChanMaxthon <email@hidden> wrote:
> Given that Apple's Foundation does not support getting NSRunLoop from CFRunLoopRef, Cocotron designed CFRunLoop using toll-free bridging from NSRunLoop and GNUstep have a NSRunLoopFromCFRunLoop() (and GNUstep have some some NSRunLoop extensions allowing implementing this mess without fussing with CF.) function in their CoreFoundation implementation, is it safe to pass whatever object I got from the underlying framework over to the upper layer, with proper warning in the documentation?
It's not clear what you're asking.
CFRunLoop and NSRunLoop are _not_ toll-free bridged. If some code is written to expect an NSRunLoop, it is not safe to pass it a CFRunLoop.
If the class's methods (designed to be overridden by subclasses) are written to take a CFRunLoop, all of your problems go away. Why are you working so hard to avoid using CFRunLoop?
Regards,
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