diff --git a/ChangeLog b/ChangeLog index f3498d32b..a52230938 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2001-05-04 Adam Fedor + + * Headers/gnustep/base/objc-gnu2next.h: Add arglist_h def. Add + encoding functions defs. + * Source/mframe.m: Include stdio and ctype. + * Source/mframe/mframe.foot (mframe_arg_addr): Use marg_getRef if + NeXT_RUNTIME. + 2001-05-04 Richard Frith-Macdonald * Source/NSDate.m: GSTimeNow() remove volatile typespec and move diff --git a/Headers/gnustep/base/objc-gnu2next.h b/Headers/gnustep/base/objc-gnu2next.h index 3855a1322..308d4c435 100644 --- a/Headers/gnustep/base/objc-gnu2next.h +++ b/Headers/gnustep/base/objc-gnu2next.h @@ -31,7 +31,11 @@ #include #include -#define arglist_t marg_list +typedef union { + char *arg_ptr; + char arg_regs[sizeof (char*)]; +} *arglist_t; /* argument frame */ +//#define arglist_t marg_list #define retval_t void* #define TypedStream void* @@ -119,6 +123,18 @@ extern void *(*_objc_realloc)(void *, size_t); extern void *(*_objc_calloc)(size_t, size_t); extern void (*_objc_free)(void *); +/* encoding functions */ +extern int objc_sizeof_type(const char* type); +extern int objc_alignof_type(const char* type); +extern int objc_aligned_size (const char* type); +extern int objc_promoted_size (const char* type); +extern const char *objc_skip_type_qualifiers (const char* type); +extern const char *objc_skip_typespec (const char* type); +extern const char *objc_skip_argspec (const char* type); +extern unsigned objc_get_type_qualifiers (const char* type); +extern BOOL sel_types_match (const char* t1, const char* t2); + + #endif /* NeXT_RUNTIME */ #endif /* __objc_gnu2next_h_GNUSTEP_BASE_INCLUDE */ diff --git a/Source/mframe.m b/Source/mframe.m index aa7e0b08a..8d8a9c0f8 100644 --- a/Source/mframe.m +++ b/Source/mframe.m @@ -34,7 +34,9 @@ #include #include #include +#include #include +#include /* Deal with strrchr: */ #if STDC_HEADERS || HAVE_STRING_H diff --git a/Source/mframe/configure b/Source/mframe/configure index 3e65b796e..3609f41f9 100755 --- a/Source/mframe/configure +++ b/Source/mframe/configure @@ -668,6 +668,7 @@ esac case "$target_os" in freebsd*) target_os=freebsd;; openbsd*) target_os=openbsd;; + darwin*) target_os=darwin;; esac diff --git a/Source/mframe/configure.in b/Source/mframe/configure.in index e544e3347..d07575267 100644 --- a/Source/mframe/configure.in +++ b/Source/mframe/configure.in @@ -40,6 +40,7 @@ esac case "$target_os" in freebsd*) target_os=freebsd;; openbsd*) target_os=openbsd;; + darwin*) target_os=darwin;; esac diff --git a/Source/mframe/mframe.foot b/Source/mframe/mframe.foot index 812d0240c..ba8f5d49c 100644 --- a/Source/mframe/mframe.foot +++ b/Source/mframe/mframe.foot @@ -9,6 +9,9 @@ mframe_arg_addr(arglist_t argf, NSArgumentInfo *info) offset += sizeof(int) - info->size; } #endif +#if NeXT_RUNTIME + return marg_getRef(argf, offset, void); +#else if (info->isReg) { return(argf->arg_regs + offset); @@ -17,6 +20,7 @@ mframe_arg_addr(arglist_t argf, NSArgumentInfo *info) { return(argf->arg_ptr + offset); } +#endif } inline static void diff --git a/Source/objc-gnu2next.m b/Source/objc-gnu2next.m index 9a958354e..9fa587588 100644 --- a/Source/objc-gnu2next.m +++ b/Source/objc-gnu2next.m @@ -259,7 +259,7 @@ objc_promoted_size (const char* type) occuring in method prototype encodings. */ -inline const char* +const char* objc_skip_type_qualifiers (const char* type) { while (*type == _C_CONST