fix exports for functor module

This commit is contained in:
Stephen Diehl
2016-12-12 16:10:49 +00:00
parent 257a38f68f
commit c7eeb5349e
+8 -4
View File
@@ -6,9 +6,12 @@ module Functor (
Functor(..),
($>),
(<$>),
(<<$>>),
void,
) where
import Data.Function ((.))
#if (__GLASGOW_HASKELL__ >= 710)
import Data.Functor (
Functor(..)
@@ -23,16 +26,17 @@ import Data.Functor (
)
import Data.Function (flip)
import Data.Function ((.))
infixl 4 $>
($>) :: Functor f => f a -> b -> f b
($>) = flip (<$)
(<<$>>) :: (Functor f, Functor g) => (a -> b) -> f (g a) -> f (g b)
(<<$>>) = fmap . fmap
void :: Functor f => f a -> f ()
void x = () <$ x
#endif
infixl 4 <<$>>
(<<$>>) :: (Functor f, Functor g) => (a -> b) -> f (g a) -> f (g b)
(<<$>>) = fmap . fmap