
17 Oct
2015
17 Oct
'15
10:37 p.m.
Hello haskellers, I'm writing FFI bindings to C library which uses some allocations across functions call, for example: int *alloc_buf(void); void free_buf(int *); So I need to use newForeignPtr to make sure buffer will be free'd when all pointers to it get collected. But what if I want to do this in PrimMonad (say, ST) and not IO (returned by newForeignPtr)? Thanks.
3619
Age (days ago)
3619
Last active (days ago)
0 comments
1 participants
participants (1)
-
Alexey Egorov