You mean I have to use a type like StablePtr (IORef Stuff)?
Because there I can only "peek" (deRefStablePtr) the pointer, not "poke" it.
I take it I should return to C a StablePtr to the new value if I don't want to use IORefs...
Or else I have to use regular Ptrs with Foreign.Marshall.Alloc.malloc
On Sun, Feb 12, 2012 at 3:09 PM, Yves Parès <yves.pares@gmail.com> wrote:http://hackage.haskell.org/packages/archive/base/latest/doc/html/Foreign-StablePtr.html#v:deRefStablePtr
> But then,
> In use case 1), how can a Haskell function modify the data addressed?
>
Antoine