Skip to content

Commit 7834ce6

Browse files
committed
Uppercase exception
1 parent f785aaf commit 7834ce6

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/Control/Monad/Eff/Exception.purs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
-- | This module defines an effect, actions and handlers for working
22
-- | with Javascript exceptions.
33

4-
module Control.Monad.Eff.Exception
5-
( Exception()
4+
module Control.Monad.Eff.Exception
5+
( EXCEPTION()
66
, Error()
77
, error
88
, message
99
, throwException
1010
, catchException
1111
) where
1212

13-
import Control.Monad.Eff
13+
import Control.Monad.Eff (Eff())
1414

1515
-- | This effect is used to annotate code which possibly throws exceptions
16-
foreign import data Exception :: !
16+
foreign import data EXCEPTION :: !
1717

1818
-- | The type of Javascript errors
1919
foreign import data Error :: *
@@ -51,7 +51,7 @@ foreign import message
5151
-- | ```purescript
5252
-- | main = do
5353
-- | x <- readNumber
54-
-- | when (x < 0) $ throwException $
54+
-- | when (x < 0) $ throwException $
5555
-- | error "Expected a non-negative number"
5656
-- | ```
5757
foreign import throwException
@@ -61,11 +61,11 @@ foreign import throwException
6161
throw e;
6262
};
6363
}
64-
""" :: forall a eff. Error -> Eff (err :: Exception | eff) a
64+
""" :: forall a eff. Error -> Eff (err :: EXCEPTION | eff) a
6565

6666
-- | Catch an exception by providing an exception handler.
6767
-- |
68-
-- | This handler removes the `Exception` effect.
68+
-- | This handler removes the `EXCEPTION` effect.
6969
-- |
7070
-- | For example:
7171
-- |
@@ -90,4 +90,4 @@ foreign import catchException
9090
};
9191
};
9292
}
93-
""" :: forall a eff. (Error -> Eff eff a) -> Eff (err :: Exception | eff) a -> Eff eff a
93+
""" :: forall a eff. (Error -> Eff eff a) -> Eff (err :: EXCEPTION | eff) a -> Eff eff a

0 commit comments

Comments
 (0)