ghci question
Duncan Coutts
duncan.coutts at worc.ox.ac.uk
Tue Apr 3 20:33:33 EDT 2007
On Wed, 2007-04-04 at 00:01 +0100, Frederik Eaton wrote:
> Hello,
>
> This is a bit lame but I don't know where to find the information...
>
> I am wondering if ghci is OK to use with threads now. It seems to work
> but I have written down in some of my source code that a certain
> function won't work under ghci because it uses threads and I can't
> remember what the symptom of the problem was.
Some Haskell libs that bind to foreign thread-unsafe libraries cannot
safely be used with multiple Haskell threads in the threaded runtime
system (and of course ghhci uses the threaded rts these days).
In particular GUI libs are affected by this. For example you can use
Gtk2Hs in GHCi, but if you forkIO and call GUI stuff from multiple
threads... boom (or more likely an xlib error or segfault). There's info
on the Gtk2Hs site about how to do it safely.
Duncan
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs at haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs
More information about the Glasgow-haskell-bugs
mailing list