e536efa5ef6221abe508202795a687e79232c8a1
[haskell-report.git] / report / lib-hdrs / Maybe.hs
1 module Maybe(
2 isJust, isNothing,
3 fromJust, fromMaybe, listToMaybe, maybeToList,
4 catMaybes, mapMaybe,
5
6 -- ...and what the Prelude exports
7 Maybe(Nothing, Just),
8 maybe
9 ) where
10
11 isJust, isNothing :: Maybe a -> Bool
12 fromJust :: Maybe a -> a
13 fromMaybe :: a -> Maybe a -> a
14 listToMaybe :: [a] -> Maybe a
15 maybeToList :: Maybe a -> [a]
16 catMaybes :: [Maybe a] -> [a]
17 mapMaybe :: (a -> Maybe b) -> [a] -> [b]