ForeignObj.makeForeignObj

Simon Marlow simonmar at microsoft.com
Mon Oct 30 06:23:17 EST 2000


> isn't right in 4.08 (or the CVS repo.) If the assumption is 
> that ForeignObj
> cannot be mutated once created (which looks like being the 
> case now since
> writeForeignObj is marked as deprecated), the defn should be 
> something like:
> 
> makeForeignObj :: Addr -> Addr -> IO ForeignObj
> makeForeignObj adr finAdr = newForeignObj adr (ap0 finAdr adr)
> 
> foreign import dynamic ap0 :: Addr -> Addr -> IO ()
> 
> In the current version the finaliser isn't parameterised with 
> the finalised
> pointer.

Thanks, I've fixed it in the CVS sources.

Cheers,
	Simon




More information about the Glasgow-haskell-bugs mailing list