[EMAIL PROTECTED] (Marcin 'Qrczak' Kowalczyk) wrote,

> Fri, 18 Aug 2000 00:01:45 +1000, Manuel M. T. Chakravarty <[EMAIL PROTECTED]> 
>pisze:
> 
> > > Assuming that the only finalized things will be ForeignObj, touch can
> > > have the type ForeignObj -> IO (). Perhaps it's be more efficient to
> > > touch the ForeignObj# inside ForeignObj.
> > 
> > How about about objects that got a finalizer with addFinalizer?
> 
> Simon Marlow told that addFinalizer is unsafe. The object can be
> silently reboxed and then the finalizer can fire much earlier anyway.

Yes, but if I understand correctly (a) addFinalizer is
unsafe only for some types and (b) maybe the problem can
eventually be resolved.  So, I wouldn't want to exclude the
possibility that we can use addFinalizer sometime in the
future.  Therefore, it seems like a good idea to me to make
the type of touch a bit more general.  Hmm, on the other
hand if we generalise the type later, old code wouldn't break
either.

Simon, Sven, what do you think?

Manuel


Reply via email to