monoids-0.1.36: Monoids, specialized containers and a general map/reduce frameworkSource codeContentsIndex
Data.Monoid.Combinators
Portabilitynon-portable (type families, MPTCs)
Stabilityexperimental
Maintainerekmett@gmail.com
Contents
List-Like Monoid Production
QuickCheck Properties
Description

Utilities for working with Monoids that conflict with names from the Prelude, Data.Foldable, Control.Monad or elsewhere. Intended to be imported qualified.

 import Data.Monoid.Combinators as Monoid 
Synopsis
repeat :: Reducer e m => e -> m
replicate :: (Monoid m, Integral n) => m -> n -> m
cycle :: Monoid m => m -> m
prop_replicate_right_distributive :: (Eq m, Monoid m, Arbitrary m, Integral n) => m -> n -> n -> Bool
List-Like Monoid Production
repeat :: Reducer e m => e -> mSource
A generalization of Data.List.repeat to an arbitrary Monoid. May fail to terminate for some values in some monoids.
replicate :: (Monoid m, Integral n) => m -> n -> mSource
A generalization of Data.List.replicate to an arbitrary Monoid. Adapted from http://augustss.blogspot.com/2008/07/lost-and-found-if-i-write-108-in.html
cycle :: Monoid m => m -> mSource
A generalization of Data.List.cycle to an arbitrary Monoid. May fail to terminate for some values in some monoids.
QuickCheck Properties
prop_replicate_right_distributive :: (Eq m, Monoid m, Arbitrary m, Integral n) => m -> n -> n -> BoolSource
Produced by Haddock version 2.3.0