Finalizers etcetera

Alastair Reid alastair at
Wed Oct 9 11:09:07 EDT 2002

> What hasn't been required is for the various data structures to be
> in a consistent state at that point, and Haskell finalizers might
> trip over those if run after GC.  SimonM's patch ran them at a
> different point, though.

It calls them in eval doesn't it?
eval is called by nearly every primitive in Hugs.
Most calls are benign since the calls are at the start of the primop
before any data structures have been fiddled with.

It's even possible that none have any problems.  All I'm saying that
we will have to look over the code before we know if there is a
problem (while others are claiming that there couldn't possibly be a

What is definitely a problem is the issue of atomicity of user-written
Haskell finalizers. 


More information about the FFI mailing list