[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: CoreBase toll-free bridging
From: |
David Chisnall |
Subject: |
Re: CoreBase toll-free bridging |
Date: |
Mon, 11 Mar 2013 17:07:46 +0000 |
On 11 Mar 2013, at 16:33, Stefan Bidi <address@hidden> wrote:
> You can just treat NSConstantString as an ObjC-only class and call the
> appropriate methods. That's how this should work now, but I haven't
> really spent a lot of time testing it.
>
> CFGetTypeID() is a complete hack, right now. The code checks for
> cf->_typeID no matter what, and if doesn't match what the system
> thinks it should be calls the method -_cfTypeID, which in turn returns
> _kCFRuntimeNotATypeID for none CF types.
As I recall, on OS X the isa pointer for bridged types contains the typeid.
The Objective-C runtime has some extra logic that checks if the isa pointer is
<= 0xffff and, if so, looks up the class from a table. The open source CFLite
stuff doesn't have this.
David
- Re: CoreBase toll-free bridging, (continued)
Re: CoreBase toll-free bridging, David Chisnall, 2013/03/11
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/11
- Re: CoreBase toll-free bridging, David Chisnall, 2013/03/11
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/11
- Re: CoreBase toll-free bridging, Stefan Bidi, 2013/03/11
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/11
- Re: CoreBase toll-free bridging, Riccardo Mottola, 2013/03/11
- Re: CoreBase toll-free bridging, Stefan Bidi, 2013/03/11
- Re: CoreBase toll-free bridging,
David Chisnall <=
- Re: CoreBase toll-free bridging, Chan Maxthon, 2013/03/11
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/11
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/13
- Re: CoreBase toll-free bridging, Richard Frith-Macdonald, 2013/03/13
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/13
- Re: CoreBase toll-free bridging, Jean-Charles BERTIN, 2013/03/13
- Re: CoreBase toll-free bridging, Fred Kiefer, 2013/03/14
- Re: CoreBase toll-free bridging, Luboš Doležel, 2013/03/14
- Re: CoreBase toll-free bridging, David Chisnall, 2013/03/14
- FreeBSD with ObjC (was Re: CoreBase toll-free bridging), Derek Fawcus, 2013/03/14