Re: Addr# field in ForeignPtr

2011-06-01 Thread Simon Marlow
On 01/06/2011 08:29, Roman Leshchinskiy wrote: GHC defines ForeignPtr as: data ForeignPtr a = ForeignPtr Addr# ForeignPtrContents -- we cache the Addr# in the ForeignPtr object, but attach -- the finalizer to the IORef (or the MutableByteArray# in -- the case of a Mal

Addr# field in ForeignPtr

2011-06-01 Thread Roman Leshchinskiy
Hi all, GHC defines ForeignPtr as: data ForeignPtr a = ForeignPtr Addr# ForeignPtrContents -- we cache the Addr# in the ForeignPtr object, but attach -- the finalizer to the IORef (or the MutableByteArray# in -- the case of a MallocPtr). The aim of the representation