2010-10-12 Nicola Pero <nicola.pero@meta-innovation.com>
* archive.c: Do not include objc/objc.h.
* class.c: Do not include objc/objc.h.
* encoding.c: Include objc/runtime.h, ctype.h and
objc-private/module-abi-8.h instead of objc/objc-api.h and
objc/encoding.h.
* error.c: Do not include objc/objc.h.
* gc.c: Include tconfig.h and objc/encoding.h only if
OBJC_WITH_GC.
* hash.c: Include objc/runtime.h and objc/thr.h instead of
objc/objc-api.h. Do not include objc/objc.h.
* init.c: Do not include objc/objc.h.
* ivars.c: Include objc/runtime.h, objc-private/module-abi-8.h and
objc/thr.h instead of objc/objc-api.h. Do not include
objc/objc.h.
* linking.m: Tidied comment.
* memory.c: Include objc/runtime.h instead of objc/objc-api.h.
Do not include objc/objc.h.
* objects.c: Do not include objc/objc.h.
* objc-sync.c: Include objc/runtime.h instead of objc/objc-api.h.
* protocols.c: Do not include objc/objc.h.
* sarray.c: Include objc/runtime.h instead of objc/objc-api.h. Do
not include objc/objc.h.
* selector.c: Do not include objc/objc.h.
* sendmsg.c: Do not include objc/objc.h.
* thr.c: Include objc/runtime.h instead of objc/objc-api.h.
Do not include objc/objc.h.
* objc/objc-decls.h: Reindented code.
* objc/runtime.h Include objc-decls.h. Updated comments.
(objc_malloc): New.
(objc_atomic_malloc): New.
(objc_calloc): New.
(objc_realloc): New.
(objc_free): New.
* objc-private/runtime.h: Updated comments.
From-SVN: r165386
2010-10-11 Nicola Pero <nicola.pero@meta-innovation.com>
* objc/objc.h: Updated comments.
* objc/objc-api.h: (object_copy): Added one argument; use a
#define to maintain backwards-compatibility. Moved
_objc_object_alloc, _objc_object_copy, _objc_object_dispose and
objc_get_uninstalled_dtable into
objc/deprecated/objc_get_uninstalled_dtable.h and
objc/deprecated/objc_object_alloc.h. Include these files.
* objc/deprecated/objc_get_uninstalled_dtable.h: New.
* objc/deprecated/objc_object_alloc.h: New.
* objc/runtime.h (set_getName): New.
(sel_getType): New.
(sel_getUid): New.
(sel_registerName): New.
(sel_registerTypedName): New.
(sel_isEqual): New.
(class_createInstance): New.
(object_copy): New.
(object_dispose): New.
* objects.c: Do not include tconfig.h. Include gc_typed.h if
building the garbage collection version.
(__objc_object_alloc): Removed.
(__objc_object_copy): Removed.
(__objc_object_dispose): Removed.
(class_createInstance): New from code in class_create_instance.
Cast second argument of GC_malloc_explicitly_typed. Use
objc_calloc. Do not call _objc_object_alloc.
(class_create_instance): Call class_createInstance.
(object_copy): Added extraBytes argument. Do not call
_objc_object_copy.
(object_dispose): Do not call _objc_object_dispose.
* memory.c (objc_free): When using garbage collection, mark the
argument as unused.
* selector.c (sel_getName): New.
(sel_get_name): Call sel_getName.
(sel_getType): New.
(sel_get_type): Call sel_getType.
(sel_registerName): New.
(sel_register_name): Call sel_registerName.
(sel_registerTypedName): New.
(sel_register_typed_name): Call sel_registerTypedName.
(sel_getUid): New.
(sel_get_uid): Call sel_getUid.
From-SVN: r165264
* Makefile.in (%_gc.lo): New pattern rules to build the
garbage-collected version of the library. Removed rules for
specific files that are no longer needed. Standardized all rules.
(C_SOURCE_FILES, OBJC_SOURCE_FILES): New variables.
(OBJS, OBJS_GC): Compute these from C_SOURCE_FILES and
OBJC_SOURCE_FILES.
(INCLUDES): Removed the unused include -I$(srcdir)/objc.
* memory.c (objc_calloc): Fixed call to GC_malloc when building
with Garbage Colletion.
From-SVN: r164231
* objc/deprecated/objc_malloc.h: New file.
* objc/deprecated/objc_valloc.h: New file.
* objc/objc-api.h: Include the files instead of defining
objc_valloc, _objc_malloc() and similar.
* Makefile.in (OBJC_DEPRECATED_H): Added objc_valloc.h and
objc_malloc.h.
* memory.c: Removed the extra layer of indirection of _objc_malloc
and similar.
(objc_calloc): Use GC_malloc in the garbage-collected
implementation as GC_malloc returns memory that is already freed.
(objc_valloc): Deprecated.
From-SVN: r164224
* objc/deprecated/objc_error.h: New file.
* objc/objc-api.h: Include deprecated/objc_error.h instead of
defining objc_error and related.
* error.c: New file. Added _objc_abort function which replaces
objc_error. No change in functionality as they both print an
error and abort.
* misc.c: File removed. Code moved into memory.c and error.c.
* memory.c: New file.
* objc-private/error.h: New file.
* archive.c: Include objc-private/error.h and use _objc_abort
instead of objc_error everywhere.
* class.c: Same change.
* encoding.c: Same change.
* init.c: Same change, and simplified init_check_module_version.
* memory.c: Same change.
* sendmsg.c: Same change.
* thr.c: Same change.
* Makefile.in (OBJ_DEPRECATED_H): Added objc_error.h.
(OBJ_H): Reordered list.
(OBJS): Removed misc.lo, added memory.lo and error.lo.
(OBJS_GC): Removed misc_gc.lo, added memory_gc.lo and error_gc.lo.
(misc_gc.lo): Rule removed.
(error_gc.lo): Rule added.
(memory_gc.lo): Rule added.
From-SVN: r164223