method: -1,
}
- makeFuncFFI(ftyp, impl)
+ makeFuncFFI(ftyp, unsafe.Pointer(impl))
return Value{t, unsafe.Pointer(&impl), flag(Func) | flagIndir}
}
rcvr: rcvr,
}
- makeFuncFFI(ftyp, fv)
+ makeFuncFFI(ftyp, unsafe.Pointer(fv))
return Value{ft, unsafe.Pointer(&fv), v.flag&flagRO | flag(Func) | flagIndir}
}
rcvr: v,
}
- makeFuncFFI(ftyp, impl)
+ makeFuncFFI(ftyp, unsafe.Pointer(impl))
return Value{t, unsafe.Pointer(&impl), v.flag&flagRO | flag(Func) | flagIndir}
}
// The makeFuncFFI function, written in C, fills in an FFI closure.
// It arranges for ffiCall to be invoked directly from FFI.
-func makeFuncFFI(ftyp *funcType, impl *makeFuncImpl)
+func makeFuncFFI(ftyp *funcType, impl unsafe.Pointer)
// FFICallbackGo implements the Go side of the libffi callback.
// It is exported so that C code can call it.
/* Declare C functions with the names used to call from Go. */
-void makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl)
+void makeFuncFFI(const struct __go_func_type *ftyp, void *impl)
__asm__ (GOSYM_PREFIX "reflect.makeFuncFFI");
#ifdef USE_LIBFFI_CLOSURES
/* Allocate an FFI closure and arrange to call ffi_callback. */
void
-makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl)
+makeFuncFFI(const struct __go_func_type *ftyp, void *impl)
{
ffi_cif *cif;
#else /* !defined(USE_LIBFFI_CLOSURES) */
void
-makeFuncFFI(const struct __go_func_type *ftyp, ffi_go_closure *impl)
+makeFuncFFI(const struct __go_func_type *ftyp, void *impl)
{
runtime_panicstring ("libgo built without FFI does not support "
"reflect.MakeFunc");