-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | simplified import of elementary lens-family combinators
--   
--   This module, <a>Lens.Simple</a>, just re-exports the main modules from
--   Russell O'Connor's <a>lens-family</a> package, the original van
--   Laarhoven-O'Connor lens library. <tt>lens-family</tt> is particularly
--   remarkable for its minute number of dependencies: (apart from
--   <a>mtl</a> they are all ghc 'boot' libraries); but more importantly
--   for its extreme conceptual simplicity and theoretical soundness. Much
--   of the material it contains is well-explained, from a tutorial point
--   of view, by <a>lens-tutorial</a> It is independent, self-standing and
--   readily intelligible apart from any darker more general system of
--   combinators that might attempt to extend it. Much of it ought to be in
--   the Prelude.
--   
--   Convenient import of the elementary combinators from
--   <tt>lens-family</tt>, however, a little complicated. The idea of this
--   trivial module, then, is just to make a sort of low-powered,
--   minimal-dependency, <tt>lens-family</tt> equivalent of the 800 lb
--   gorilla of lens library imports:
--   
--   <pre>
--   import Control.Lens
--   </pre>
--   
--   namely, the light-weight and elegant:
--   
--   <pre>
--   import Lens.Simple
--   </pre>
--   
--   Check it out, it's even one character shorter!
--   
--   The material in <a>lens-tutorial</a> will work fine if you make this
--   substitution in the underlying <a>source</a> and follow along as
--   prompted.
--   
--   As another illustration of the simplicity of the fundamental van
--   Laarhoven-O'Connor lens combinators - and their homogeneity with
--   <tt>Control.Lens</tt> - note that the gloss <a>pong example</a> from
--   the <tt>lens</tt> library examples directory - which continues to be
--   among the best introductory lens tutorials precisely by saying nothing
--   - requires only this abbreviating change of imports.
--   
--   If you make that program more complicated, you might of course end up
--   needing the more sophisticated material in <tt>Control.Lens</tt> and
--   its immense mass of dependencies. On the other hand, you might just
--   need some of the additional material present in the similarly
--   demystifying <a>microlens</a> or <a>microlens-th</a> and the
--   associated modules.
--   
--   This module was originally intended to simplify the use of packages
--   that follow the original promise of the van Laarhoven-O'Connor lenses.
--   <i>Correct practice is to export lenses without depending on a
--   lens-library, where possible.</i> In basic cases these just use
--   familiar <tt>Prelude</tt> types, after all. Examples of best practices
--   in this respect are e.g. <a>lens-family-th</a> which doesn't depend on
--   <tt>lens-family</tt> despite its name and pipes-related packages like
--   <a>pipes-bytestring</a> and <a>pipes-group</a>.
--   
--   <tt>Lens.Simple</tt> also re-exports convenient TH incantations like
--   <tt>makeLenses</tt> from Dan Burton's associated
--   <a>lens-family-th</a>.
@package lens-simple
@version 0.1.0.9

module Lens.Simple

-- | <pre>
--   view :: Getter a a' b b' -&gt; a -&gt; b
--   </pre>
--   
--   Demote a lens or getter to a projection function.
--   
--   <pre>
--   view :: Monoid b =&gt; Fold a a' b b' -&gt; a -&gt; b
--   </pre>
--   
--   Returns the monoidal summary of a traversal or a fold.
view :: () => FoldLike b a a' b b' -> a -> b

-- | Set all referenced fields to the given value.
set :: () => Setter a a' b b' -> b' -> a -> a'

-- | Demote a setter to a semantic editor combinator.
over :: () => ASetter a a' b b' -> (b -> b') -> a -> a'

-- | Lens on the first element of a pair.
_1 :: () => Lens (a, b) (a', b) a a'

-- | Lens on the second element of a pair.
_2 :: () => Lens (a, b) (a, b') b b'

-- | Traversal on the <a>Left</a> element of an <a>Either</a>.
_Left :: () => Traversal (Either a b) (Either a' b) a a'

-- | Traversal on the <a>Right</a> element of an <a>Either</a>.
_Right :: () => Traversal (Either a b) (Either a b') b b'

-- | Traversal on the <a>Just</a> element of a <a>Maybe</a>.
_Just :: () => Traversal (Maybe a) (Maybe a') a a'

-- | Traversal on the <a>Nothing</a> element of a <a>Maybe</a>.
_Nothing :: () => Traversal' (Maybe a) ()

-- | Traversals on both elements of a pair <tt>(a,a)</tt>.
both :: () => Traversal (a, a) (b, b) a b
type Lens a a' b b' = forall (f :: Type -> Type). Functor f => LensLike f a a' b b'
type Traversal a a' b b' = forall (f :: Type -> Type). Applicative f => LensLike f a a' b b'
type Setter a a' b b' = forall (f :: Type -> Type). Identical f => LensLike f a a' b b'
type Getter a a' b b' = forall (f :: Type -> Type). Phantom f => LensLike f a a' b b'
type Fold a a' b b' = forall (f :: Type -> Type). (Phantom f, Applicative f) => LensLike f a a' b b'
type FoldLike r a a' b b' = LensLike (Constant r :: Type -> Type) a a' b b'
type SetterLike a a' b b' = LensLike Identity a a' b b'
type LensLike (f :: Type -> Type) a a' b b' = b -> f b' -> a -> f a'

-- | Build a lens from a <tt>getter</tt> and <tt>setter</tt> families.
--   
--   <i>Caution</i>: In order for the generated lens family to be
--   well-defined, you must ensure that the three lens laws hold:
--   
--   <ul>
--   <li><pre>getter (setter a b) === b</pre></li>
--   <li><pre>setter a (getter a) === a</pre></li>
--   <li><pre>setter (setter a b1) b2) === setter a b2</pre></li>
--   </ul>
lens :: () => (a -> b) -> (a -> b' -> a') -> Lens a a' b b'

-- | Build a lens from isomorphism families.
--   
--   <i>Caution</i>: In order for the generated lens family to be
--   well-defined, you must ensure that the two isomorphism laws hold:
--   
--   <ul>
--   <li><pre>yin . yang === id</pre></li>
--   <li><pre>yang . yin === id</pre></li>
--   </ul>
iso :: () => (a -> b) -> (b' -> a') -> Lens a a' b b'

-- | <a>to</a> promotes a projection function to a read-only lens called a
--   getter. To demote a lens to a projection function, use the section
--   <tt>(^.l)</tt> or <tt>view l</tt>.
--   
--   <pre>
--   &gt;&gt;&gt; (3 :+ 4, "example")^._1.to(abs)
--   5.0 :+ 0.0
--   </pre>
to :: () => (a -> b) -> Getter a a' b b'

-- | <a>setting</a> promotes a "semantic editor combinator" to a
--   modify-only lens. To demote a lens to a semantic edit combinator, use
--   the section <tt>(l %~)</tt> or <tt>over l</tt> from
--   <a>Lens.Family2</a>.
--   
--   <pre>
--   &gt;&gt;&gt; setting map . fstL %~ length $ [("The",0),("quick",1),("brown",1),("fox",2)]
--   [(3,0),(5,1),(5,1),(3,2)]
--   </pre>
--   
--   <i>Caution</i>: In order for the generated setter family to be
--   well-defined, you must ensure that the two functors laws hold:
--   
--   <ul>
--   <li><pre>sec id === id</pre></li>
--   <li><pre>sec f . sec g === sec (f . g)</pre></li>
--   </ul>
setting :: () => ((b -> b') -> a -> a') -> Setter a a' b b'

-- | <a>folding</a> promotes a "toList" function to a read-only traversal
--   called a fold.
--   
--   To demote a traversal or fold to a "toList" function use the section
--   <tt>(^..l)</tt> or <tt>toListOf l</tt>.
folding :: Foldable f => (a -> f b) -> Fold a a' b b'

-- | <pre>
--   (^.) :: a -&gt; Getter a a' b b' -&gt; b
--   </pre>
--   
--   Access the value referenced by a getter or lens.
--   
--   <pre>
--   (^.) :: Monoid b =&gt; a -&gt; Fold a a' b b' -&gt; b
--   </pre>
--   
--   Access the monoidal summary referenced by a getter or lens.
(^.) :: () => a -> FoldLike b a a' b b' -> b
infixl 8 ^.

-- | Modify all referenced fields.
(%~) :: () => Setter a a' b b' -> (b -> b') -> a -> a'
infixr 4 %~

-- | Set all referenced fields to the given value.
(.~) :: () => Setter a a' b b' -> b' -> a -> a'
infixr 4 .~

-- | <a>&amp;</a> is a reverse application operator. This provides
--   notational convenience. Its precedence is one higher than that of the
--   forward application operator <a>$</a>, which allows <a>&amp;</a> to be
--   nested in <a>$</a>.
--   
--   <pre>
--   &gt;&gt;&gt; 5 &amp; (+1) &amp; show
--   "6"
--   </pre>
(&) :: () => a -> (a -> b) -> b
infixl 1 &

-- | Generalized infix flip, replicating <tt>Control.Lens.Lens.??</tt>
--   
--   <pre>
--   &gt;&gt;&gt; execStateT ?? (0,"") $ do _1 += 1; _1 += 1; _2 &lt;&gt;= "hello"
--   (2,"hello")
--   </pre>
(??) :: Functor f => f (a -> b) -> a -> f b
infixl 1 ??
(?~) :: Setter a a' b (Maybe b') -> b' -> a -> a'

-- | Returns a list of all of the referenced values in order.
(^..) :: () => a -> Fold a a' b b' -> [b]
infixl 8 ^..

-- | Returns <a>Just</a> the first referenced value. Returns <a>Nothing</a>
--   if there are no referenced values.
(^?) :: () => a -> Fold a a' b b' -> Maybe b
infixl 8 ^?

-- | <pre>
--   zoom :: Monad m =&gt; Lens' a b -&gt; StateT b m c -&gt; StateT a m c
--   </pre>
--   
--   Lift a stateful operation on a field to a stateful operation on the
--   whole state. This is a good way to call a "subroutine" that only needs
--   access to part of the state.
--   
--   <pre>
--   zoom :: (Monoid c, Monad m) =&gt; Traversal' a b -&gt; StateT b m c -&gt; StateT a m c
--   </pre>
--   
--   Run the "subroutine" on each element of the traversal in turn and
--   <a>mconcat</a> all the results together.
--   
--   <pre>
--   zoom :: Monad m =&gt; Traversal' a b -&gt; StateT b m () -&gt; StateT a m ()
--   </pre>
--   
--   Run the "subroutine" on each element the traversal in turn.
zoom :: Monad m => LensLike' (Zooming m c) a b -> StateT b m c -> StateT a m c

-- | <pre>
--   use :: MonadState a m =&gt; Getter a a' b b' -&gt; m b
--   </pre>
--   
--   Retrieve a field of the state
--   
--   <pre>
--   use :: (Monoid b, MonadState a m) =&gt; Fold a a' b b' -&gt; m b
--   </pre>
--   
--   Retrieve a monoidal summary of all the referenced fields from the
--   state
use :: MonadState a m => FoldLike b a a' b b' -> m b

-- | <pre>
--   uses :: (MonadState a m, Monoid r) =&gt; Fold a a' b b' -&gt; (b -&gt; r) -&gt; m r
--   </pre>
--   
--   Retrieve all the referenced fields from the state and foldMap the
--   results together with <tt>f :: b -&gt; r</tt>.
--   
--   <pre>
--   uses :: MonadState a m =&gt; Getter a a' b b' -&gt; (b -&gt; r) -&gt; m r
--   </pre>
--   
--   Retrieve a field of the state and pass it through the function <tt>f
--   :: b -&gt; r</tt>.
--   
--   <pre>
--   uses l f = f &lt;$&gt; use l
--   </pre>
uses :: MonadState a m => FoldLike r a a' b b' -> (b -> r) -> m r

-- | Set a field of the state.
assign :: MonadState a m => Setter a a b b' -> b' -> m ()

-- | Modify a field of the state.
(%=) :: MonadState a m => Setter a a b b' -> (b -> b') -> m ()
infix 4 %=

-- | Set a field of the state.
(.=) :: MonadState a m => Setter a a b b' -> b' -> m ()
infix 4 .=

-- | <pre>
--   (%%=) :: MonadState a m =&gt; Lens a a b b' -&gt; (b -&gt; (c, b')) -&gt; m c
--   </pre>
--   
--   Modify a field of the state while returning another value.
--   
--   <pre>
--   (%%=) :: (MonadState a m, Monoid c) =&gt; Traversal a a b b' -&gt; (b -&gt; (c, b')) -&gt; m c
--   </pre>
--   
--   Modify each field of the state and return the <a>mconcat</a> of the
--   other values.
(%%=) :: MonadState a m => LensLike (Writer c) a a b b' -> (b -> (c, b')) -> m c
infix 4 %%=

-- | Set a field of the state using the result of executing a stateful
--   command.
(<~) :: MonadState a m => Setter a a b b' -> m b' -> m ()
infixr 2 <~
(+~) :: Num b => Setter' a b -> b -> a -> a
infixr 4 +~
(*~) :: Num b => Setter' a b -> b -> a -> a
infixr 4 *~
(-~) :: Num b => Setter' a b -> b -> a -> a
infixr 4 -~
(//~) :: Fractional b => Setter' a b -> b -> a -> a
infixr 4 //~
(&&~) :: () => Setter' a Bool -> Bool -> a -> a
infixr 4 &&~
(||~) :: () => Setter' a Bool -> Bool -> a -> a
infixr 4 ||~

-- | Monoidally append a value to all referenced fields.
(<>~) :: Monoid o => Setter' a o -> o -> a -> a
infixr 4 <>~
(+=) :: (MonadState a m, Num b) => Setter' a b -> b -> m ()
infixr 4 +=
(-=) :: (MonadState a m, Num b) => Setter' a b -> b -> m ()
infixr 4 -=
(*=) :: (MonadState a m, Num b) => Setter' a b -> b -> m ()
infixr 4 *=
(//=) :: (MonadState a m, Fractional b) => Setter' a b -> b -> m ()
infixr 4 //=
(&&=) :: MonadState a m => Setter' a Bool -> Bool -> m ()
infixr 4 &&=
(||=) :: MonadState a m => Setter' a Bool -> Bool -> m ()
infixr 4 ||=

-- | Monoidally append a value to all referenced fields of the state.
(<>=) :: (Monoid o, MonadState a m) => Setter' a o -> o -> m ()
infixr 4 <>=

-- | Lens on the Left or Right element of an (<a>Either</a> a a).
chosen :: () => Lens (Either a a) (Either b b) a b

-- | Lens on a given point of a function.
ix :: Eq k => k -> Lens' (k -> v) v

-- | Lens on a given point of a <a>Map</a>.
at :: Ord k => k -> Lens' (Map k v) (Maybe v)

-- | Lens on a given point of a <a>IntMap</a>.
intAt :: () => Int -> Lens' (IntMap v) (Maybe v)

-- | Lens on a given point of a <a>Set</a>.
contains :: Ord k => k -> Lens' (Set k) Bool

-- | Lens on a given point of a <a>IntSet</a>.
intContains :: Int -> Lens' IntSet Bool

-- | The empty traveral on any type.
ignored :: () => Traversal a a b b'

-- | An SEC referencing the parameter of a functor.
mapped :: Functor f => Setter (f a) (f a') a a'

-- | <pre>
--   views :: Monoid r =&gt; Fold a a' b b' -&gt; (b -&gt; r) -&gt; a -&gt; r
--   </pre>
--   
--   Given a fold or traversal, return the <a>foldMap</a> of all the values
--   using the given function.
--   
--   <pre>
--   views :: Getter a a' b b' -&gt; (b -&gt; r) -&gt; a -&gt; r
--   </pre>
--   
--   <a>views</a> is not particularly useful for getters or lenses, but
--   given a getter or lens, it returns the referenced value passed through
--   the given function.
--   
--   <pre>
--   views l f a = f (view l a)
--   </pre>
views :: () => FoldLike r a a' b b' -> (b -> r) -> a -> r

-- | Returns a list of all of the referenced values in order.
toListOf :: () => Fold a a' b b' -> a -> [b]

-- | Returns true if all of the referenced values satisfy the given
--   predicate.
allOf :: () => Fold a a' b b' -> (b -> Bool) -> a -> Bool

-- | Returns true if any of the referenced values satisfy the given
--   predicate.
anyOf :: () => Fold a a' b b' -> (b -> Bool) -> a -> Bool

-- | Returns <a>Just</a> the first referenced value. Returns <a>Nothing</a>
--   if there are no referenced values. See <a>^?</a> for an infix version
--   of <a>firstOf</a>
firstOf :: () => Fold a a' b b' -> a -> Maybe b

-- | Returns <a>Just</a> the last referenced value. Returns <a>Nothing</a>
--   if there are no referenced values.
lastOf :: () => Fold a a' b b' -> a -> Maybe b

-- | Returns the sum of all the referenced values.
sumOf :: Num b => Fold a a' b b' -> a -> b

-- | Returns the product of all the referenced values.
productOf :: Num b => Fold a a' b b' -> a -> b

-- | Counts the number of references in a traversal or fold for the input.
lengthOf :: Num r => Fold a a' b b' -> a -> r

-- | Returns true if the number of references in the input is zero.
nullOf :: () => Fold a a' b b' -> a -> Bool

-- | <pre>
--   backwards :: Traversal a a' b b' -&gt; Traversal a a' b b'
--   backwards :: Fold a a' b b' -&gt; Fold a a' b b'
--   </pre>
--   
--   Given a traversal or fold, reverse the order that elements are
--   traversed.
--   
--   <pre>
--   backwards :: Lens a a' b b' -&gt; Lens a a' b b'
--   backwards :: Getter a a' b b' -&gt; Getter a a' b b'
--   backwards :: Setter a a' b b' -&gt; Setter a a' b b'
--   </pre>
--   
--   No effect on lenses, getters or setters.
backwards :: () => LensLike (Backwards f) a a' b b' -> LensLike f a a' b b'

-- | <pre>
--   choosing :: Lens a a' c c' -&gt; Lens b b' c c' -&gt; Lens (Either a b) (Either a' b') c c'
--   </pre>
--   
--   <pre>
--   choosing :: Traversal a a' c c' -&gt; Traversal b b' c c' -&gt; Traversal (Either a b) (Either a' b') c c'
--   </pre>
--   
--   <pre>
--   choosing :: Getter a a' c c' -&gt; Getter b b' c c' -&gt; Getter (Either a b) (Either a' b') c c'
--   </pre>
--   
--   <pre>
--   choosing :: Fold a a' c c' -&gt; Fold b b' c c' -&gt; Fold (Either a b) (Either a' b') c c'
--   </pre>
--   
--   <pre>
--   choosing :: Setter a a' c c' -&gt; Setter b b' c c' -&gt; Setter (Either a b) (Either a' b') c c'
--   </pre>
--   
--   Given two lens/traversal/getter/fold/setter families with the same
--   substructure, make a new lens/traversal/getter/fold/setter on
--   <a>Either</a>.
choosing :: Functor f => LensLike f a a' c c' -> LensLike f b b' c c' -> LensLike f (Either a b) (Either a' b') c c'

-- | <pre>
--   alongside :: Lens a1 a1' b1 b1' -&gt; Lens a2 a2' b2 b2' -&gt; Lens (a1, a2) (a1', a2') (b1, b2) (b1', b2')
--   </pre>
--   
--   <pre>
--   alongside :: Getter a1 a1' b1 b1' -&gt; Getter a2 a2' b2 b2' -&gt; Getter (a1, a2) (a1', a2') (b1, b2) (b1', b2')
--   </pre>
--   
--   Given two lens/getter families, make a new lens/getter on their
--   product.
alongside :: Functor f => LensLike (AlongsideLeft f b2') a1 a1' b1 b1' -> LensLike (AlongsideRight f a1') a2 a2' b2 b2' -> LensLike f (a1, a2) (a1', a2') (b1, b2) (b1', b2')

-- | <pre>
--   beside :: Traversal a a' c c' -&gt; Traversal b' b' c c' -&gt; Traversal (a,b) (a',b') c c'
--   </pre>
--   
--   <pre>
--   beside :: Fold a a' c c' -&gt; Fold b' b' c c' -&gt; Fold (a,b) (a',b') c c'
--   </pre>
--   
--   <pre>
--   beside :: Setter a a' c c' -&gt; Setter b' b' c c' -&gt; Setter (a,b) (a',b') c c'
--   </pre>
--   
--   Given two traversals/folds/setters referencing a type <tt>c</tt>,
--   create a traversal/fold/setter on the pair referencing <tt>c</tt>.
beside :: Applicative f => LensLike f a a' c c' -> LensLike f b b' c c' -> LensLike f (a, b) (a', b') c c'

-- | Derive lenses for the record selectors in a single-constructor data
--   declaration, or for the record selector in a newtype declaration.
--   Lenses will only be generated for record fields which are prefixed
--   with an underscore.
--   
--   Example usage:
--   
--   <pre>
--   $(makeLenses ''Foo)
--   </pre>
makeLenses :: Name -> Q [Dec]

-- | Derive traversals for each constructor in a data or newtype
--   declaration, Traversals will be named by prefixing the constructor
--   name with an underscore.
--   
--   Example usage:
--   
--   <pre>
--   $(makeTraversals ''Foo)
--   </pre>
makeTraversals :: Name -> Q [Dec]

-- | Derive lenses with the provided name transformation and filtering
--   function. Produce <tt>Just lensName</tt> to generate a lens of the
--   resultant name, or <tt>Nothing</tt> to not generate a lens for the
--   input record name.
--   
--   Example usage:
--   
--   <pre>
--   $(makeLensesBy (\n -&gt; Just (n ++ "L")) ''Foo)
--   </pre>
makeLensesBy :: (String -> Maybe String) -> Name -> Q [Dec]

-- | Derive lenses, specifying explicit pairings of <tt>(fieldName,
--   lensName)</tt>.
--   
--   Example usage:
--   
--   <pre>
--   $(makeLensesFor [("_foo", "fooLens"), ("bar", "lbar")] ''Foo)
--   </pre>
makeLensesFor :: [(String, String)] -> Name -> Q [Dec]
type LensLike' (f :: Type -> Type) a b = b -> f b -> a -> f a
type Lens' a b = forall (f :: Type -> Type). Functor f => LensLike' f a b
type Traversal' a b = forall (f :: Type -> Type). Applicative f => LensLike' f a b
type Getter' a b = forall (f :: Type -> Type). Phantom f => LensLike' f a b
type Setter' a b = forall (f :: Type -> Type). Identical f => LensLike' f a b
type FoldLike' r a b = LensLike' (Constant r :: Type -> Type) a b
type ASetter' a b = LensLike' Identity a b
type ASetter a a' b b' = LensLike Identity a a' b b'
class Applicative f => Identical (f :: Type -> Type)
class Functor f => Phantom (f :: Type -> Type)
data AlongsideLeft (f :: Type -> Type) b a
data AlongsideRight (f :: Type -> Type) a b
data Zooming (m :: Type -> Type) c a

-- | Constant functor.
newtype Constant a (b :: k) :: forall k. () => Type -> k -> Type
Constant :: a -> Constant a
[getConstant] :: Constant a -> a

-- | Identity functor and monad. (a non-strict monad)
newtype Identity a
Identity :: a -> Identity a
[runIdentity] :: Identity a -> a

-- | The class of monoids (types with an associative binary operation that
--   has an identity). Instances should satisfy the following laws:
--   
--   <ul>
--   <li><pre>x <a>&lt;&gt;</a> <a>mempty</a> = x</pre></li>
--   <li><pre><a>mempty</a> <a>&lt;&gt;</a> x = x</pre></li>
--   <li><tt>x <a>&lt;&gt;</a> (y <a>&lt;&gt;</a> z) = (x <a>&lt;&gt;</a>
--   y) <a>&lt;&gt;</a> z</tt> (<a>Semigroup</a> law)</li>
--   <li><pre><a>mconcat</a> = <a>foldr</a> '(&lt;&gt;)'
--   <a>mempty</a></pre></li>
--   </ul>
--   
--   The method names refer to the monoid of lists under concatenation, but
--   there are many other instances.
--   
--   Some types can be viewed as a monoid in more than one way, e.g. both
--   addition and multiplication on numbers. In such cases we often define
--   <tt>newtype</tt>s and make those instances of <a>Monoid</a>, e.g.
--   <tt>Sum</tt> and <tt>Product</tt>.
--   
--   <b>NOTE</b>: <a>Semigroup</a> is a superclass of <a>Monoid</a> since
--   <i>base-4.11.0.0</i>.
class Semigroup a => Monoid a

-- | Identity of <a>mappend</a>
mempty :: Monoid a => a

-- | An associative operation
--   
--   <b>NOTE</b>: This method is redundant and has the default
--   implementation <tt><a>mappend</a> = '(&lt;&gt;)'</tt> since
--   <i>base-4.11.0.0</i>.
mappend :: Monoid a => a -> a -> a

-- | Fold a list using the monoid.
--   
--   For most types, the default definition for <a>mconcat</a> will be
--   used, but the function is included in the class definition so that an
--   optimized version can be provided for specific types.
mconcat :: Monoid a => [a] -> a

-- | An associative operation.
(<>) :: Semigroup a => a -> a -> a
infixr 6 <>
