RE: Why I want Haskell finalizers

2002-10-17 Thread Simon Marlow
> > No, that's only a partial (and indeed very incomplete) solution. It > > relies on the Java GC knowing that that particular reference to the > > Haskell StablePtr is the only one that matters, and vice-versa for > > the Haskell GC. > > So you want StablePtrs to contain a reference count, a n

Re: Why I want Haskell finalizers

2002-10-16 Thread Alastair Reid
>> So what you want is for the Java GC to call hs_freeStablePtr on all >> the Haskell objects that just died? > No, that's only a partial (and indeed very incomplete) solution. It > relies on the Java GC knowing that that particular reference to the > Haskell StablePtr is the only one that matt

Re: Why I want Haskell finalizers

2002-10-16 Thread George Russell
Alastair Reid wrote: > > George writes: > > If you have Haskell talking to some > > other language with a garbage collector, be it Java or SML, then at > > a given point of the program you can in general expect to have > > Haskell holding stable pointers to objects referenced from their > > world

Re: Why I want Haskell finalizers

2002-10-16 Thread Alastair Reid
George writes: > If you have Haskell talking to some > other language with a garbage collector, be it Java or SML, then at > a given point of the program you can in general expect to have > Haskell holding stable pointers to objects referenced from their > world by the other language, and vice-ve