
I think there is a tendency to look at IO as bad because pure code is so much better. But it's important to keep things in perspective - the existence of something better doesn't make something bad. IO is still better than the best of most other languages.
I have been bashing IO from time to time on lambda-the-ultimate.org (LtU). I can't say I got a lot of response, so I don't think there's a lot of hate around. The thing about IO is that it solves one problem well: interfacing with an imperative sequential world. Old manners like stream handling functions are just plain awkward and need some kind rendezvous; uniqueness typing is fast, composable, but a bit awkward too, and -truth be told- better encapsulated in its own monad probably anyway. There also is certainly a case that banning benign side effects might have a lot more to do with the fact that that is inherently difficult in a lazy pure language (and compiler for that) than that it's so bad for the average programmer. The thing against the IO monad is not that there's anything wrong with it. Just that it kind of locks programmers into a style of programming, I believe, functional programming is just trying to avoid, i.e., imperative programming. The whole point of old-school functional programming was (always) to declaratively build libraries out of combinators which implement a specific purpose. Now, I don't know Haskell that well, but it feels to me that a lot of libraries written are now in a sequential imperative style instead of that combinatorial style. So, I, for one, are not against IO, but consider it something which should be avoided instead of cuddled. Cheers, Marco (Sorry for sending multiple copies James; the woes of gmail... sigh...)