Don't look for actual OldException.Exception exceptions
authorIan Lynagh <igloo@earth.li>
Tue, 2 Sep 2008 22:47:30 +0000 (22:47 +0000)
committerIan Lynagh <igloo@earth.li>
Tue, 2 Sep 2008 22:47:30 +0000 (22:47 +0000)
We don't actually throw them (we throw the new Exception equivalents
instead), and looking for them was causing an infinite loop

Control/OldException.hs

index 7036912..7e5ebc8 100644 (file)
@@ -710,8 +710,7 @@ instance New.Exception Exception where
       Just exc -> Just (f exc)
       _        -> e
     casters =
-      [Caster (\e -> e),
-       Caster (\exc -> ArithException exc),
+      [Caster (\exc -> ArithException exc),
        Caster (\exc -> ArrayException exc),
        Caster (\(New.AssertionFailed err) -> AssertionFailed err),
        Caster (\exc -> AsyncException exc),