mirror of
https://github.com/darlinghq/darling-libobjc2.git
synced 2024-11-30 15:40:47 +00:00
Return NULL instead of "" from sel_getTypes_np() - matches behaviour of sel_get_types() and makes more sense.
This commit is contained in:
parent
ded142ebff
commit
c40f9e84f2
13
dtable.c
13
dtable.c
@ -8,18 +8,25 @@
|
||||
|
||||
SparseArray *__objc_uninstalled_dtable;
|
||||
|
||||
/**
|
||||
* Structure for maintaining a linked list of temporary dtables. When sending
|
||||
* an +initialize message to a class, we create a temporary dtables and store
|
||||
* it in a linked list. This is then used when sending other messages to
|
||||
* instances of classes in the middle of initialisation.
|
||||
*/
|
||||
typedef struct _InitializingDtable
|
||||
{
|
||||
/** The class that owns the dtable. */
|
||||
Class class;
|
||||
/** The dtable for this class. */
|
||||
void *dtable;
|
||||
/** The next uninstalled dtable in the list. */
|
||||
struct _InitializingDtable *next;
|
||||
} InitializingDtable;
|
||||
|
||||
/** Protected by initialize_lock */
|
||||
/** Head of the list of temporary dtables. Protected by initialize_lock. */
|
||||
InitializingDtable *temporary_dtables;
|
||||
|
||||
static SparseArray *create_dtable_for_class (Class class);
|
||||
|
||||
static uint32_t dtable_depth = 8;
|
||||
|
||||
void __objc_init_dispatch_tables ()
|
||||
|
@ -273,7 +273,7 @@ SEL sel_registerTypedName_np(const char *selName, const char *types)
|
||||
|
||||
const char *sel_getType_np(SEL aSel)
|
||||
{
|
||||
return (NULL == aSel->types) ? "" : aSel->types;
|
||||
return aSel->types;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user