+2010-09-08 Nicola Pero <nicola@nicola.brainstorm.co.uk>
+
+ * objc/typedstream.h: Deprecate all functions in the file. This
+ file is obsolete.
+ * objc/Object.h ([+streamVersion:], [-read:], [-write:],
+ [-awake]): Documented that these methods are deprecated. Added a
+ brief description of the Object class and its relationship to the
+ NSObject class.
+ * Makefile.in: Compile archive.c and Object.m with
+ -Wno-deprecated-declarations.
+
2010-09-08 Nicola Pero <nicola.pero@meta-innovation.com>
Removed obsolete intermediate threading layer.
rm -f tmp-runtime.m tmp-runtime.s
archive_gc.lo: archive.c
- $(LIBTOOL_COMPILE) $(CC) -c -o $@ $(ALL_CFLAGS) $(OBJC_GCFLAGS) \
+ $(LIBTOOL_COMPILE) $(CC) -Wno-deprecated-declarations -c -o $@ $(ALL_CFLAGS) \
+ $(OBJC_GCFLAGS) $(INCLUDES) $<
+
+archive.lo: archive.c
+ $(LIBTOOL_COMPILE) $(CC) -Wno-deprecated-declarations -c $(ALL_CFLAGS) \
$(INCLUDES) $<
class_gc.lo: class.c
$(LIBTOOL_COMPILE) $(CC) -fgnu-runtime -c -o $@ $(ALL_CFLAGS) \
$(OBJC_GCFLAGS) $(INCLUDES) $<
+# -Wno-deprecated-declarations is for the objc/typedstream.h functions.
Object.lo: Object.m
- $(LIBTOOL_COMPILE) $(CC) -fgnu-runtime -c -o $@ $(ALL_CFLAGS) \
- $(INCLUDES) $<
+ $(LIBTOOL_COMPILE) $(CC) -fgnu-runtime -Wno-deprecated-declarations \
+ -c -o $@ $(ALL_CFLAGS) $(INCLUDES) $<
+# -Wno-deprecated-declarations is for the objc/typedstream.h functions.
Object_gc.lo: Object.m
- $(LIBTOOL_COMPILE) $(CC) -fgnu-runtime -c -o $@ $(ALL_CFLAGS) \
- $(OBJC_GCFLAGS) $(INCLUDES) $<
+ $(LIBTOOL_COMPILE) $(CC) -fgnu-runtime -Wno-deprecated-declarations \
+ -c -o $@ $(ALL_CFLAGS) $(OBJC_GCFLAGS) $(INCLUDES) $<
objects_gc.lo: objects.c
$(LIBTOOL_COMPILE) $(CC) -c $(ALL_CFLAGS) -o $@ $(OBJC_GCFLAGS) \
/* Interface for the Object class for Objective-C.
- Copyright (C) 1993, 1994, 1995, 2009 Free Software Foundation, Inc.
+ Copyright (C) 1993, 1994, 1995, 2009, 2010 Free Software Foundation, Inc.
This file is part of GCC.
extern "C" {
#endif
+/* The Object class is a minimal (but fully functional) root class
+ included with the runtime.
+
+ It is mostly for testing the runtime; very handy in configure
+ tests, and when writing language/runtime testcases.
+
+ Because Objective-C allows multiple root classes, a Foundation
+ library (such as GNUstep-base) is expected to provide its own root
+ class (typically called NSObject), fully integrated with the
+ library's own high-level features. If you are using such a
+ Foundation library, you should most likely use its root class for
+ everything and ignore Object.
+*/
+
/*
- * All classes are derived from Object. As such,
- * this is the overhead tacked onto those objects.
+ All classes are derived from Object. As such,
+ this is the overhead tacked onto those objects.
*/
@interface Object
{
/* Archiving */
+ (int)version;
+ setVersion:(int)aVersion;
-+ (int)streamVersion: (TypedStream*)aStream;
-- read: (TypedStream*)aStream;
-- write: (TypedStream*)aStream;
-- awake;
+/* The following methods were deprecated in GCC 4.6.0 and will be removed in the next
+ GCC release.
+*/
++ (int)streamVersion: (TypedStream*)aStream; /* __attribute__ ((deprecated)) */
+
+- read: (TypedStream*)aStream; /* __attribute__ ((deprecated)) */
+- write: (TypedStream*)aStream; /* __attribute__ ((deprecated)) */
+- awake; /* __attribute__ ((deprecated)) */
@end
#ifndef __typedstream_INCLUDE_GNU
#define __typedstream_INCLUDE_GNU
+/* The API in this file was entirely deprecated in GCC 4.6.0 and will
+ be removed in the following GCC release.
+*/
+
#include "objc.h"
#include "hash.h"
** arguments are pointers to the objects to read/write.
*/
-int objc_write_type (TypedStream* stream, const char* type, const void* data);
-int objc_read_type (TypedStream* stream, const char* type, void* data);
+int objc_write_type (TypedStream* stream, const char* type, const void* data) __attribute__ ((deprecated));
+int objc_read_type (TypedStream* stream, const char* type, void* data) __attribute__ ((deprecated));
-int objc_write_types (TypedStream* stream, const char* type, ...);
-int objc_read_types (TypedStream* stream, const char* type, ...);
+int objc_write_types (TypedStream* stream, const char* type, ...) __attribute__ ((deprecated));
+int objc_read_types (TypedStream* stream, const char* type, ...) __attribute__ ((deprecated));
-int objc_write_object_reference (TypedStream* stream, id object);
-int objc_write_root_object (TypedStream* stream, id object);
+int objc_write_object_reference (TypedStream* stream, id object) __attribute__ ((deprecated));
+int objc_write_root_object (TypedStream* stream, id object) __attribute__ ((deprecated));
-long objc_get_stream_class_version (TypedStream* stream, Class class_type);
+long objc_get_stream_class_version (TypedStream* stream, Class class_type) __attribute__ ((deprecated));
/*
*/
int objc_write_array (TypedStream* stream, const char* type,
- int count, const void* data);
+ int count, const void* data) __attribute__ ((deprecated));
int objc_read_array (TypedStream* stream, const char* type,
- int count, void* data);
+ int count, void* data) __attribute__ ((deprecated));
-int objc_write_object (TypedStream* stream, id object);
-int objc_read_object (TypedStream* stream, id* object);
+int objc_write_object (TypedStream* stream, id object) __attribute__ ((deprecated));
+int objc_read_object (TypedStream* stream, id* object) __attribute__ ((deprecated));
** OBJC_READONLY or OBJC_WRITEONLY.
*/
-TypedStream* objc_open_typed_stream (FILE* physical, int mode);
-TypedStream* objc_open_typed_stream_for_file (const char* file_name, int mode);
+TypedStream* objc_open_typed_stream (FILE* physical, int mode) __attribute__ ((deprecated));
+TypedStream* objc_open_typed_stream_for_file (const char* file_name, int mode) __attribute__ ((deprecated));
-void objc_close_typed_stream (TypedStream* stream);
+void objc_close_typed_stream (TypedStream* stream) __attribute__ ((deprecated));
-BOOL objc_end_of_typed_stream (TypedStream* stream);
-void objc_flush_typed_stream (TypedStream* stream);
+BOOL objc_end_of_typed_stream (TypedStream* stream) __attribute__ ((deprecated));
+void objc_flush_typed_stream (TypedStream* stream) __attribute__ ((deprecated));
#ifdef __cplusplus
}