FFI function pointers with unlifted argument types
Motivation
I noticed today that GHC disallows using the function pointer wrapper
facilities when the function in question has any unlifted arguments. For example:
type KafkaLog = Addr# -> Int# -> Addr# -> Addr# -> IO ()
foreign import ccall "wrapper"
mkCompare :: KafkaLog -> IO (FunPtr KafkaLog)
Turning on UnliftedFFITypes
does not address the problem
Proposal
Allow unlifted types to show up as arguments to wrapped functions when UnliftedFFITypes
is enabled.