14 Jun
2004
14 Jun
'04
4:50 p.m.
Keith Wansbrough wrote:
s/fail/error/ s/return//
Then you can easily write
I can't (easily) write
text c = sqr x + sqr (x+1)
You just can't *catch* this outside the IO monad.
Of course... that was my second alternative error strategy. I'm interest in how/when people decide when to throw exceptions versus when to thread errors using monads, given that changing code from one to the other could be quite a big deal. Tim