Skip to content

Commit 6182e6b

Browse files
committed
Merge pull request #17 from zudov/master
Remove explicit type annotations for `id`
2 parents 1e65d7c + 31e140c commit 6182e6b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Data/Maybe.purs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ maybe' _ f (Just a) = f a
4949
-- | fromMaybe x (Just y) == y
5050
-- | ```
5151
fromMaybe :: forall a. a -> Maybe a -> a
52-
fromMaybe a = maybe a (id :: forall a. a -> a)
52+
fromMaybe a = maybe a id
5353

5454
-- | Similar to `fromMaybe` but for use in cases where the default value may be
5555
-- | expensive to compute. As PureScript is not lazy, the standard `fromMaybe`
@@ -61,7 +61,7 @@ fromMaybe a = maybe a (id :: forall a. a -> a)
6161
-- | fromMaybe' (\_ -> x) (Just y) == y
6262
-- | ```
6363
fromMaybe' :: forall a. (Unit -> a) -> Maybe a -> a
64-
fromMaybe' a = maybe' a (id :: forall a. a -> a)
64+
fromMaybe' a = maybe' a id
6565

6666
-- | Returns `true` when the `Maybe` value was constructed with `Just`.
6767
isJust :: forall a. Maybe a -> Boolean

0 commit comments

Comments
 (0)