[project @ 2003-08-04 17:30:53 by panne]
[ghc-base.git] / Control / Exception.hs
index c766002..2db472f 100644 (file)
@@ -104,7 +104,7 @@ module Control.Exception (
        bracket,        -- :: IO a -> (a -> IO b) -> (a -> IO c) -> IO ()
        bracket_,       -- :: IO a -> IO b -> IO c -> IO ()
 
-       finally,        -- :: IO a -> IO b -> IO b
+       finally,        -- :: IO a -> IO b -> IO a
 
   ) where
 
@@ -124,7 +124,7 @@ import System.IO.Error      hiding ( catch, try )
 import System.IO.Unsafe (unsafePerformIO)
 import Data.Dynamic
 
-#include "Dynamic.h"
+#include "Typeable.h"
 INSTANCE_TYPEABLE0(Exception,exceptionTc,"Exception")
 INSTANCE_TYPEABLE0(IOException,ioExceptionTc,"IOException")
 INSTANCE_TYPEABLE0(ArithException,arithExceptionTc,"ArithException")
@@ -165,7 +165,7 @@ INSTANCE_TYPEABLE0(AsyncException,asyncExceptionTc,"AsyncException")
 --
 -- Also note that The "Prelude" also exports a
 -- function called 'catch' which has the same type as
--- 'Exception.catch', the difference being that the
+-- 'Control.Exception.catch', the difference being that the
 -- "Prelude" version only catches the IO and user
 -- families of exceptions (as required by Haskell 98).  We recommend
 -- either hiding the "Prelude" version of
@@ -236,7 +236,7 @@ evaluate a = IO $ \s -> case a `seq` () of () -> (# s, a #)
 -- 'mapException'
 
 -- | This function maps one exception into another as proposed in the
--- paper "A semantics for imprecise exceptions".
+-- paper \"A semantics for imprecise exceptions\".
 
 -- Notice that the usage of 'unsafePerformIO' is safe here.
 
@@ -288,7 +288,7 @@ throwDyn exception = throw (DynException (toDyn exception))
 
 #ifdef __GLASGOW_HASKELL__
 -- | A variant of 'throwDyn' that throws the dynamic exception to an
--- arbitrary thread (c.f. 'throwTo').
+-- arbitrary thread (GHC only: c.f. 'throwTo').
 throwDynTo :: Typeable exception => ThreadId -> exception -> IO ()
 throwDynTo t exception = throwTo t (DynException (toDyn exception))
 #endif /* __GLASGOW_HASKELL__ */
@@ -421,7 +421,7 @@ The primary source of asynchronous exceptions, however, is
 
 >  throwTo :: ThreadId -> Exception -> IO ()
 
-'throwTo' (also 'throwDynTo' and 'Concurrent.killThread') allows one
+'throwTo' (also 'throwDynTo' and 'Control.Concurrent.killThread') allows one
 running thread to raise an arbitrary exception in another thread.  The
 exception is therefore asynchronous with respect to the target thread,
 which could be doing anything at the time it receives the exception.
@@ -477,7 +477,7 @@ With 'takeMVar' interruptible, however, we can be
 safe in the knowledge that the thread can receive exceptions right up
 until the point when the 'takeMVar' succeeds.
 Similar arguments apply for other interruptible operations like
-'IO.openFile'.
+'GHC.Handle.openFile'.
 -}
 
 -- -----------------------------------------------------------------------------