RE: Simple concurrent issue?

2000-08-03 Thread Simon Marlow
OTOH, certainly doing an IO operation should cause a thread switch. In my limited use of the concurrency extension, I found it hard to write a dining philosophers program that behaved randomly. I had to throw yield's in all over the place. The `GHC-specific concurrency issues' of the

Re: Simple concurrent issue?

2000-08-02 Thread Kevin Glynn
OTOH, certainly doing an IO operation should cause a thread switch. In my limited use of the concurrency extension, I found it hard to write a dining philosophers program that behaved randomly. I had to throw yield's in all over the place. The `GHC-specific concurrency issues' of the hslibs

Simple concurrent issue?

2000-08-01 Thread Hannah Schroeter
Hello! When running this program under GHC 4.08 (OpenBSD 2.7, x86), only "b"s are written. Shouldn't GHC's implementation of Concurrent Haskell be preemptive? Regards, Hannah. import Concurrent main = forkIO a b where a = putStrLn "a" a b = putStrLn "b" b