[Haskell-cafe] Simple network client

Jules Bean jules at jellybean.co.uk
Wed Jan 30 17:46:09 EST 2008

Dan Weston wrote:
> Now I'm confused (which happens quite a lot, I'm afraid!)
> Prelude> readFile undefined
> *** Exception: Prelude.undefined
> Prelude> readFile undefined >>= \cs -> putStrLn "Hello"
> *** Exception: Prelude.undefined
> It seems that readFile is strict in its argument. As for getLine, it has 
> no argument to be strict in.

This is the confusion between strict/lazy in the ordinary language 
semantics sense, and strictIO/ 


More information about the Haskell-Cafe mailing list