universe-reverse-instances-1.1.2: Instances of standard classes that are made possible by enumerations
Safe HaskellSafe
LanguageHaskell2010

Data.Universe.Instances.Traversable

Description

A Foldable instance for functions, given the input is Finite, and a Traversable instance for functions, given the input is Ord and Finite.

Orphan instances

Finite e => Foldable ((->) e) Source # 
Instance details

Methods

fold :: Monoid m => (e -> m) -> m #

foldMap :: Monoid m => (a -> m) -> (e -> a) -> m #

foldMap' :: Monoid m => (a -> m) -> (e -> a) -> m #

foldr :: (a -> b -> b) -> b -> (e -> a) -> b #

foldr' :: (a -> b -> b) -> b -> (e -> a) -> b #

foldl :: (b -> a -> b) -> b -> (e -> a) -> b #

foldl' :: (b -> a -> b) -> b -> (e -> a) -> b #

foldr1 :: (a -> a -> a) -> (e -> a) -> a #

foldl1 :: (a -> a -> a) -> (e -> a) -> a #

toList :: (e -> a) -> [a] #

null :: (e -> a) -> Bool #

length :: (e -> a) -> Int #

elem :: Eq a => a -> (e -> a) -> Bool #

maximum :: Ord a => (e -> a) -> a #

minimum :: Ord a => (e -> a) -> a #

sum :: Num a => (e -> a) -> a #

product :: Num a => (e -> a) -> a #

(Ord e, Finite e) => Traversable ((->) e) Source # 
Instance details

Methods

traverse :: Applicative f => (a -> f b) -> (e -> a) -> f (e -> b) #

sequenceA :: Applicative f => (e -> f a) -> f (e -> a) #

mapM :: Monad m => (a -> m b) -> (e -> a) -> m (e -> b) #

sequence :: Monad m => (e -> m a) -> m (e -> a) #