[Narrowing to cvs-ghc]

So Axel says "we are doomed" and Manuel says "it's easy".

I don't want GHC 6.10.2 to "fundamentally break" GtkHs.

Let's resolve this.

Simon


| -----Original Message-----
| From: [email protected] [mailto:glasgow-haskell-users-
| [email protected]] On Behalf Of Manuel M T Chakravarty
| Sent: 25 March 2009 01:17
| To: jutaro
| Cc: [email protected]
| Subject: Re: ANNOUNCE: GHC 6.10.2 Release Candidate 1
|
| jutaro:
| > This is the first answer I got from the gtk2hs mailing list. Please
| > consider
| > this issue seriously.
|
| Well there is a simple fix as Simon Marlow wrote,
| > The fix is fiarly easy: use Foreign.Concurrent.mkForeignPtr with a
| > foreign import.
|
| In fact, if as Axel writes, these finalisers are Haskell functions
| that are exported using foreign import wrapper, then using
| Foreign.Concurrent.mkForeignPtr is actually the *simpler* thing to do
| (you don't need any wrapping and exporting).
|
| Manuel
|
| > Axel Simon wrote:
| >>
| >>
| >> Phew,
| >>
| >> I think we're doomed. We have many, many little methods that take a
| >> user-given function, wrap it into a foreign export wrapper which is
| >> freed by using an on-destroy callback to Haskell. These functions are
| >> most likely installed into some widgets (or other reference-counted
| >> objects) that will be eventually destroyed by the Haskell garbage
| >> collector. So, basically, we can't easily change Gtk2Hs. It will
| >> involve many modifications. I can understand that not allowing
| >> callbacks during GC is a great simplification in the runtime but it
| >> seemed to be common practice to free Stable and function pointers
| >> from within Haskell using a callback.
| >>
| >> So, unless I'm wrong on why finalizers call back into Haskell land,
| >> then this means that Gtk2Hs is fundamentally broken for the
| >> foreseeable future.
| >>
| >> Axel.
|
| _______________________________________________
| Glasgow-haskell-users mailing list
| [email protected]
| http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to