Differences From Artifact [18895befa5]:
- File
src/runtime/ObjFW_RT.h
— part of check-in
[482698c5be]
at
2018-05-06 21:39:06
on branch trunk
— runtime: Make Amiga library work with -fbaserel
This currently uses __saveds on all exported functions for simplicity.
As an optimization, __saveds can be removed from some functions later
after careful verification that no code path starting from that function
accesses any data. (user: js, size: 12257) [annotate] [blame] [check-ins using]
To Artifact [3f56631b9e]:
- File src/runtime/ObjFW_RT.h — part of check-in [95e1ba8d63] at 2018-05-13 02:09:02 on branch trunk — runtime: Port Amiga library to MorphOS (user: js, size: 10624) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
54 55 56 57 58 59 60 | #endif #define Nil (Class _Null_unspecified)0 #define nil (id _Null_unspecified)0 #define YES true #define NO false | < < < < < < < < < < < < < | 54 55 56 57 58 59 60 61 62 63 64 65 66 67 | #endif #define Nil (Class _Null_unspecified)0 #define nil (id _Null_unspecified)0 #define YES true #define NO false typedef struct objc_class *Class; typedef struct objc_object *id; typedef const struct objc_selector *SEL; #if !defined(__wii__) && !defined(__amigaos__) typedef bool BOOL; #endif typedef id _Nullable (*IMP)(id _Nonnull, SEL _Nonnull, ...); |
︙ | ︙ | |||
217 218 219 220 221 222 223 | long count; Protocol *__unsafe_unretained _Nonnull list[1]; }; #ifdef __cplusplus extern "C" { #endif | < < < < < < < < < < < | < | | < | < | < | | < | | < | | < | < | > > < < < < < | < | | < | | < | | < | | < < | | | < | < | < | < | < | | | | | | < | 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 | long count; Protocol *__unsafe_unretained _Nonnull list[1]; }; #ifdef __cplusplus extern "C" { #endif extern SEL _Nonnull sel_registerName(const char *_Nonnull name); extern const char *_Nonnull sel_getName(SEL _Nonnull sel); extern bool sel_isEqual(SEL _Nonnull sel1, SEL _Nonnull sel2); extern Class _Nonnull objc_allocateClassPair(Class _Nullable superclass, const char *_Nonnull name, size_t extra_bytes); extern void objc_registerClassPair(Class _Nonnull cls); extern unsigned int objc_getClassList(Class _Nonnull *_Nullable buf, unsigned int count); extern Class _Nonnull *_Nonnull objc_copyClassList(unsigned int *_Nullable len); extern bool class_isMetaClass(Class _Nullable cls); extern const char *_Nullable class_getName(Class _Nullable cls); extern Class _Nullable class_getSuperclass(Class _Nullable cls); extern unsigned long class_getInstanceSize(Class _Nullable cls); extern bool class_respondsToSelector(Class _Nullable cls, SEL _Nonnull sel); extern bool class_conformsToProtocol(Class _Nullable cls, Protocol *_Nonnull p); extern IMP _Nullable class_getMethodImplementation(Class _Nullable cls, SEL _Nonnull sel); extern IMP _Nullable class_getMethodImplementation_stret(Class _Nullable cls, SEL _Nonnull sel); extern const char *_Nullable class_getMethodTypeEncoding(Class _Nullable cls, SEL _Nonnull sel); extern bool class_addMethod(Class _Nonnull cls, SEL _Nonnull sel, IMP _Nonnull imp, const char *_Nullable types); extern IMP _Nullable class_replaceMethod(Class _Nonnull cls, SEL _Nonnull sel, IMP _Nonnull imp, const char *_Nullable types); extern Class _Nullable object_getClass(id _Nullable object); extern Class _Nullable object_setClass(id _Nullable object, Class _Nonnull cls); extern const char *_Nullable object_getClassName(id _Nullable object); extern const char *_Nonnull protocol_getName(Protocol *_Nonnull p); extern bool protocol_isEqual(Protocol *_Nonnull a, Protocol *_Nonnull b); extern bool protocol_conformsToProtocol(Protocol *_Nonnull a, Protocol *_Nonnull b); extern void objc_exit(void); extern _Nullable objc_uncaught_exception_handler objc_setUncaughtExceptionHandler( objc_uncaught_exception_handler _Nullable handler); extern void objc_setForwardHandler(IMP _Nullable forward, IMP _Nullable forward_stret); extern void objc_setEnumerationMutationHandler( objc_enumeration_mutation_handler _Nullable handler); extern void objc_zero_weak_references(id _Nonnull value); /* * Used by the compiler, but can also be called manually. * * These declarations are also required to prevent Clang's implicit * declarations which include __declspec(dllimport) on Windows. */ |
︙ | ︙ | |||
324 325 326 327 328 329 330 | extern void objc_setProperty(id _Nonnull self, SEL _Nonnull _cmd, ptrdiff_t offset, id _Nullable value, bool atomic, signed char copy); extern void objc_getPropertyStruct(void *_Nonnull dest, const void *_Nonnull src, ptrdiff_t size, bool atomic, bool strong); extern void objc_setPropertyStruct(void *_Nonnull dest, const void *_Nonnull src, ptrdiff_t size, bool atomic, bool strong); extern void objc_enumerationMutation(id _Nonnull object); | | > > > > > > | | 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 | extern void objc_setProperty(id _Nonnull self, SEL _Nonnull _cmd, ptrdiff_t offset, id _Nullable value, bool atomic, signed char copy); extern void objc_getPropertyStruct(void *_Nonnull dest, const void *_Nonnull src, ptrdiff_t size, bool atomic, bool strong); extern void objc_setPropertyStruct(void *_Nonnull dest, const void *_Nonnull src, ptrdiff_t size, bool atomic, bool strong); extern void objc_enumerationMutation(id _Nonnull object); #ifndef OBJC_NO_PERSONALITY_DECLARATION /* * No objfw-defs.h or config.h is available for the installed runtime headers, * so we don't know which exceptions we have. */ extern int __gnu_objc_personality_v0(int version, int actions, uint64_t ex_class, void *_Nonnull ex, void *_Nonnull ctx); extern int __gnu_objc_personality_sj0(int version, int actions, uint64_t ex_class, void *_Nonnull ex, void *_Nonnull ctx); #endif extern id _Nullable objc_retain(id _Nullable object); extern id _Nullable objc_retainBlock(id _Nullable block); extern id _Nullable objc_retainAutorelease(id _Nullable object); extern void objc_release(id _Nullable object); extern id _Nullable objc_autorelease(id _Nullable object); extern id _Nullable objc_autoreleaseReturnValue(id _Nullable object); extern id _Nullable objc_retainAutoreleaseReturnValue(id _Nullable object); |
︙ | ︙ |