
(+1) to that request - what is the "best practices" for portable exception handling code that straddles version 6.10, i.e. that compiles with compilers at either side with minimal fuss? I can imagine a couple of alternatives, but would like to hear what others are doing here. thanks --sigbjorn "likes backward code compatibility" On 11/1/2008 18:15, Jason Dagit wrote:
On Wed, Oct 8, 2008 at 1:19 AM, Simon Marlow
wrote: Johannes Waldmann wrote:
with 6.10, the following does not typecheck:
foo `Control.Exception.catch` \ _ -> return bar
Ambiguous type variable `e' in the constraint: `Control.Exception.Exception e'
It is probably bad programming style anyway but what is the workaround?
As long as you're aware that it is bad programming style. We deliberately didn't include an easy way to do this, because we want people to think about why they need to catch *all* exceptions (most of the time it's a bug).
Since the above is bad form, what should I be doing? Could someone please provide some examples or point me at the list of exceptions that I can catch? What about catching multiple types of exceptions?
Thanks, Jason _______________________________________________ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users