From: Malcolm.Wallace@cs.york.ac.uk Date: Wed, 13 Aug 2008 12:58:50 +0000 (+0000) Subject: No reason for Handler and catches to exclude nhc98. X-Git-Tag: 6_10_branch_has_been_forked~48 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=3f1ffd4ccf37044a52934c3fd955b1794a3ccb1a;p=ghc-base.git No reason for Handler and catches to exclude nhc98. --- diff --git a/Control/Exception.hs b/Control/Exception.hs index 1be188c..1b29913 100644 --- a/Control/Exception.hs +++ b/Control/Exception.hs @@ -35,12 +35,12 @@ module Control.Exception ( #else SomeException(..), #endif - Exception(..), -- instance Eq, Ord, Show, Typeable - IOException, -- instance Eq, Ord, Show, Typeable - ArithException(..), -- instance Eq, Ord, Show, Typeable - ArrayException(..), -- instance Eq, Ord, Show, Typeable + Exception(..), -- class + IOException, -- instance Eq, Ord, Show, Typeable, Exception + ArithException(..), -- instance Eq, Ord, Show, Typeable, Exception + ArrayException(..), -- instance Eq, Ord, Show, Typeable, Exception AssertionFailed(..), - AsyncException(..), -- instance Eq, Ord, Show, Typeable + AsyncException(..), -- instance Eq, Ord, Show, Typeable, Exception #if __GLASGOW_HASKELL__ || __HUGS__ NonTermination(..), @@ -76,9 +76,7 @@ module Control.Exception ( -- ** The @catch@ functions catch, -- :: IO a -> (Exception -> IO a) -> IO a -#if __GLASGOW_HASKELL__ || __HUGS__ catches, Handler(..), -#endif catchJust, -- :: (Exception -> Maybe b) -> IO a -> (b -> IO a) -> IO a -- ** The @handle@ functions @@ -144,7 +142,6 @@ import Prelude hiding (catch) import System (ExitCode()) #endif -#if __GLASGOW_HASKELL__ || __HUGS__ data Handler a = forall e . Exception e => Handler (e -> IO a) catches :: IO a -> [Handler a] -> IO a @@ -156,7 +153,6 @@ catchesHandler handlers e = foldr tryHandler (throw e) handlers = case fromException e of Just e' -> handler e' Nothing -> res -#endif -- ----------------------------------------------------------------------------- -- Asynchronous exceptions