gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: corebase runloop integration


From: David Chisnall
Subject: Re: corebase runloop integration
Date: Tue, 4 Feb 2014 08:45:32 +0000

On 3 Feb 2014, at 23:14, Luboš Doležel <address@hidden> wrote:

> I looked into it again:
> 
> "Methods defined in categories can replace methods defined in the class
> proper, but they cannot reliably replace methods defined in other
> categories."
> 
> I suppose this could be good enough after all. I wouldn't expect any
> other NSRunLoop overrides around.

The problem is that if someone else provides a category in a shared library, 
there is no guarantee whether yours or theirs will be loaded first, and it 
depends entirely on link / load order so may not be stable.

However, I'm not sure I understand why this is an issue for CFRunLoop.  The 
CFRunLoop is roughly analogous to GSRunLoopCtx, and so the right way of doing 
this would be to rename GSRunLoopCtx to CFRunLoop, clean up its APIs, and make 
it public.  There are multiple implementations of this currently, and it would 
also be nice to have one that used libdispatch at the core so that we could use 
libdispatch's main queue as the main thread and so on.

David




reply via email to

[Prev in Thread] Current Thread [Next in Thread]