Re: [Haskell-cafe] Implementing tryReadMVar

2004-09-02 Thread Einar Karttunen
On 01.09 18:30, MR K P SCHUPKE wrote: while channel not empty read next event if event high priority process now else queue event in FIFO process first event in FIFO That suffers from the same problem as I described. do e - isEmptyChan

Re: [Haskell-cafe] Implementing tryReadMVar

2004-09-02 Thread Einar Karttunen
On 01.09 13:09, Jan-Willem Maessen - Sun Labs East wrote: I was, however, curious what use you had in mind where writes were racing, but where you nonetheless wanted to perform blind non-blocking reads. Such situations are generally fraught with peril. In this case, the peril is

Re: [Haskell-cafe] QuickCheck - Extracting data values from tests

2004-09-02 Thread Shae Matijs Erisson
Jorge Adriano Aires [EMAIL PROTECTED] writes: Hello all, When using Quickcheck, is there some way to extract generated data values to the IO Monad? I know I can collect and print information about test cases, but that's not enough. Data may be pretty complex, and there may be no parsers

Re: [Haskell-cafe] Stack overflow in ghci

2004-09-02 Thread Ron de Bruijn
--- Tomasz Zielonka [EMAIL PROTECTED] wrote: On Thu, Sep 02, 2004 at 08:47:51AM -0700, Ron de Bruijn wrote: I heard of the +RTS option. I used: ghci SomeModule.hs -someoptions +RTS -K150, but this doesn't seem to have any effect. Try +RTS -K150M. -K150 means 150 bytes.

Re: [Haskell-cafe] Partially-applied type synonyms?

2004-09-02 Thread Lyle Kopnicky
Chung-chieh, Well, I tried what you suggested, and it seems to work. Unfortunately, it's not very useful. The point of creating MonadPCont, was, like MonadCont or MonadState, to automatically provide features to a monad built from a transformer, without having to redefine them. Since ContT

Re: [Haskell-cafe] QuickCheck - Extracting data values from tests

2004-09-02 Thread Jorge Adriano Aires
Hello all, When using Quickcheck, is there some way to extract generated data values to the IO Monad? I know I can collect and print information about test cases, but that's not enough. Data may be pretty complex, and there may be no parsers for it. If a test suddenly goes wrong,