Sometimes we may wish to use ffi.Callback to represent a function pointer that's being passed to a native function as a parameter. Today, these types get mapped as ffi.Function which isn't compatible. We should consider how to support a typed solution that allows either:
Select ffi.Function or ffi.Callback via clangffi flags or other user config (ideally selection occurs at a function level)
Provide a typing that allows for either, and let the caller decide
Sometimes we may wish to use
ffi.Callback
to represent a function pointer that's being passed to a native function as a parameter. Today, these types get mapped asffi.Function
which isn't compatible. We should consider how to support a typed solution that allows either:ffi.Function
orffi.Callback
viaclangffi
flags or other user config (ideally selection occurs at a function level)