@@ 5,6 5,7 @@
#import "OC_Mapping.h"
#include "piobjc.h"
#include "method_dispatch.h"
+#include "proxy-registry.h"
#undef THIS
#define THIS OBJ2_DYNAMIC_OBJECT(Pike_fp->current_object)
@@ 494,7 495,11 @@ LOG("encoding mapping as OC_Mapping%s\n"
case 'd':
case 'f':
msgResult = malloc(sizeof(double));
+#if defined(__aarch64__)
+ ffi_call(cif, FFI_FN(objc_msgSend), msgResult, argumentList);
+#else
ffi_call(cif, FFI_FN(objc_msgSend_fpret), msgResult, argumentList);
+#endif
break;
@@ 503,7 508,11 @@ LOG("encoding mapping as OC_Mapping%s\n"
case '(':
THREADS_ALLOW();
Pike_error("No, no, no... we've not implemented struct returns yet.\n");
+#if defined(__aarch64__)
+ ffi_call(cif, FFI_FN(objc_msgSend), msgResult, argumentList);
+#else
ffi_call(cif, FFI_FN(objc_msgSend_stret), msgResult, argumentList);
+#endif
THREADS_DISALLOW();
break;