Andrea Rossato wrote:
On Sun, Sep 14, 2008 at 02:24:23PM -0300, Marco Túlio Gontijo e Silva wrote:
and the result of ls only after I press a key.  Does getChar blocks the
other threads?

yes, but you can use forkOS from Control.Concurrent and compile with
-threaded.

See the relevant documentation for the details.

forkOS not relevant here.

-threaded is necessary to allow haskell code to run whilst FFI calls are blocked. getChar doesn't count as an FFI call (the RTS does its own IO multiplexing) but system does.

forkOS is to do with bound threads, that's something else.

Jules
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to