Differences From Artifact [c947f89bcc]:
- File
src/runtime/category.m
— part of check-in
[963db3089f]
at
2012-05-10 18:21:18
on branch runtime
— objc_hashtable_alloc() -> objc_hashtable_new().
For consistency. (user: js, size: 3183) [annotate] [blame] [check-ins using] [more...]
To Artifact [9fd764b81d]:
- File
src/runtime/category.m
— part of check-in
[345eb93240]
at
2012-07-17 01:09:50
on branch trunk
— Rename ERROR() to OBJC_ERROR().
ERROR seems to be defined on MinGW32 and it's likely that it's also used
on other systems, thus it's better to prefix it with OBJC_. (user: js, size: 3196) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
58 59 60 61 62 63 64 | struct objc_abi_category **ncats; size_t i; for (i = 0; cats[i] != NULL; i++); if ((ncats = realloc(cats, (i + 2) * sizeof(struct objc_abi_category*))) == NULL) | | | | | 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 | struct objc_abi_category **ncats; size_t i; for (i = 0; cats[i] != NULL; i++); if ((ncats = realloc(cats, (i + 2) * sizeof(struct objc_abi_category*))) == NULL) OBJC_ERROR("Not enough memory for category %s of " "class %s!", cat->category_name, cat->class_name); ncats[i] = cat; ncats[i + 1] = NULL; objc_hashtable_set(categories, cat->class_name, ncats); if (cls != Nil && cls->info & OBJC_CLASS_INFO_SETUP) { objc_update_dtable(cls); objc_update_dtable(cls->isa); } return; } if ((cats = malloc(2 * sizeof(struct objc_abi_category*))) == NULL) OBJC_ERROR("Not enough memory for category %s of class %s!\n", cat->category_name, cat->class_name); cats[0] = cat; cats[1] = NULL; objc_hashtable_set(categories, cat->class_name, cats); if (cls != Nil && cls->info & OBJC_CLASS_INFO_SETUP) { |
︙ | ︙ |