[Haskell-cafe] Re: Tutorial uploaded

Udo Stenzel u.stenzel at web.de
Wed Dec 21 09:42:31 EST 2005

Creighton Hogg wrote:
> On Wed, 21 Dec 2005, Henning Thielemann wrote:
> > The drawback is that I saw many Haskell programs implemented with IO
> > read/write functions which could be easily implemented without IO, using
> > laziness.
> Can you think of any examples of things like that?  Given 
> that I'm still learning how to take advantage of laziness 
> it'd be pretty interesting.

Here's another one:  I've heard a fellow claim, Haskell is basically
unsuitable to implement a compiler, because Haskell is weak at IO and
"everything needs IO, the lexer, the preprocessor, the parser, the
pretty-printer, ..."  Can you imagine what convoluted mess he would
write if he learned IO first?

Therefore I think, if, say, chapter 6 includes "A parser for Things is a
function from Strings to a list of Things and Strings", then chapter 7 is
the earliest that should include IO beyond getContents and putStr.  The
funny thing is, after the parser IO is simply another monad.  At this
point, the compiler becomes an imperative one-liner and lots of pure

I piss on you all from a considerable height. -- Louis Ferdinand Celine
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://www.haskell.org//pipermail/haskell-cafe/attachments/20051221/5b548b82/attachment.bin

More information about the Haskell-Cafe mailing list