how to convert an array of foreignPtr a into a list of Ptr a

27 Aug
2019
27 Aug
'19
3:19 a.m.
Hello, I am writing some code whcih use FFI. one of my C functions has an array of pointer has imput extern HklBinocularsCube *hkl_binoculars_cube_new(int32_t n_spaces, const HklBinocularsSpace **spaces); from Haskell, I have a list of ForeignPtr so my question how can I have something like withForeignPtr for an array of ForeignPtr [ForeignPtr a] -> ([Ptr a] -> IO b) -> IO b Thanks for your help. Frederic
2093
Age (days ago)
2093
Last active (days ago)
0 comments
1 participants
participants (1)
-
PICCA Frederic-Emmanuel