Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-03 Thread Richard Kelsall
Gwern Branwen wrote: ... Ultimately, the problem with Haskell and ML for our purposes is that the brightest and most aggressive programmers in those languages, using the most aggressive optimization techniques known to the research community, remain unable to write systems codes that compete

[Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Maciej Piechotka
1. Learning haskell I discovered that I/O should be avoided nearly 'at all costs'. The problem is that the IO monad is the only one which have more interactive work flow. There is Reader/Writer monad but in fact AFAIU first one is about the environment and second one is about logging.

Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Bulat Ziganshin
Hello Maciej, Thursday, July 2, 2009, 3:31:59 PM, you wrote: class (Monad m, Monoid v) = MonadInput v m where -- | Gets an element from input (line of text [with \n], 4096 bytes, -- or something like that). mzero on end getChunk :: m v class (Monad m, Monoid v) = MonadOutput v

Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Maciej Piechotka
On Thu, 2009-07-02 at 15:43 +0400, Bulat Ziganshin wrote: Hello Maciej, Thursday, July 2, 2009, 3:31:59 PM, you wrote: class (Monad m, Monoid v) = MonadInput v m where -- | Gets an element from input (line of text [with \n], 4096 bytes, -- or something like that). mzero on

Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Luke Palmer
On Thu, Jul 2, 2009 at 5:31 AM, Maciej Piechotka uzytkown...@gmail.comwrote: 2. I find writing monad transformers annoying. Additionally if package defines transformer A and another transformer B they need to be connected 'by hand'. You have not given any concrete problems or examples, so

Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Jason Dagit
On Thu, Jul 2, 2009 at 1:18 PM, Luke Palmer lrpal...@gmail.com wrote: I used to approach problems by designing a monad for my whole program, using an appropriate stack of transformers. I suspect such an approach led to the claim that monads are not appropriate for large software systems in

Re[2]: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Bulat Ziganshin
Hello Luke, Friday, July 3, 2009, 12:18:21 AM, you wrote: I used to approach problems by designing a monad for my whole program, using an appropriate stack of transformers.  I suspect such an approach led to the claim that monads are not appropriate for large software systems in a popular

Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Maciej Piechotka
On Thu, 2009-07-02 at 14:18 -0600, Luke Palmer wrote: On Thu, Jul 2, 2009 at 5:31 AM, Maciej Piechotka uzytkown...@gmail.com wrote: 2. I find writing monad transformers annoying. Additionally if package defines transformer A and another transformer B they need

Re: [Haskell-cafe] Monad Input/Output and Monad Transformers

2009-07-02 Thread Gwern Branwen
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 On Thu, Jul 2, 2009 at 5:05 PM, Maciej Piechotka wrote: I'd appreciate the link - google find nothing. I fall in love in Haskell about a week or two ago and I fall in love just after I started learning it ;) Research programming languages like