Release the storage associated with the given FunPtr, which must have been obtained from a wrapper stub. This should be called whenever the return value from a foreign import wrapper function is no longer required; otherwise, the storage it uses will leak.
Deallocate a memory pool and everything which has been allocated in the pool itself.
Dissolve the association between the stable pointer and the Haskell value. Afterwards, if the stable pointer is passed to deRefStablePtr or freeStablePtr, the behaviour is undefined. However, the stable pointer may still be passed to castStablePtrToPtr, but the Foreign.Ptr.Ptr () value returned by castStablePtrToPtr, in this case, is undefined (in particular, it may be Foreign.Ptr.nullPtr). Nevertheless, the call to castStablePtrToPtr is guaranteed not to diverge.