[Haskell-cafe] GHCi with wxhaskell-dev
dukedave at gmail.com
Tue Jan 10 19:05:22 CET 2012
I'm working on a dev branch of wxHaskell  and one of the new
features is that you can use wxHaskell in GHCi (again), but I seem to
have broken something in the process:
Firstly: wxHaskell works in GHCi insomuch as:
You can load the hello world sample  in GHCi, do "> main", see the
window spawn, close it and be returned to the GHCi prompt.
What I'm interested in is the case where you call wxHaskell's start
function  from GHCi.
The result is becoming stuck with no way back to the GHCi prompt
without resorting to sending kill signals.
I made a screen cast to illustrate my findings :
1. Once you've done "> start $ return ()" you can press ^C all you
want, there's no way back to the GHCi prompt.
2. If you send three (less has no effect) kills to the GHCi process it
will exit, but it will exit GHCi as well (instead of putting you back
at the GHCi prompt).
3. If you do "> start $ return ()" but *do not* try and ^C, you can
send a single kill to GHCi and be returned to the GHCi prompt.
1. Why doesn't GHCi respond to the ^C?
2a. Why does entering ^C from within GHCi then prevent you from
getting back to the GHCi prompt?
2b. Why doesn't any other input (i.e. entering anything but ^C) cause
3. If you have sent ^C from GHCi, why do you then have to kill three
times to get out of GHCi?
Feel free to pull the repo  and try it out, you'll need the latest
dev release of wxWidgets  installed.
More information about the Haskell-Cafe