lens-5.0.1: Lenses, Folds and Traversals
Copyright (C) 2012-2016 Edward Kmett
License BSD-style (see the file LICENSE)
Maintainer Edward Kmett <ekmett@gmail.com>
Stability experimental
Portability non-portable
Safe Haskell Safe-Inferred
Language Haskell2010

Control.Lens.Internal.Fold

Description

Synopsis

Monoids for folding

newtype Sequenced a m Source #

Used internally by mapM_ and the like.

The argument a of the result should not be used!

See 4.16 Changelog entry for the explanation of "why not Apply f =>"?

Constructors

Sequenced

Fields

getLeftmost :: Leftmost a -> Maybe a Source #

Extract the Leftmost element. This will fairly eagerly determine that it can return Just the moment it sees any element at all.

getRightmost :: Rightmost a -> Maybe a Source #

Extract the Rightmost element. This will fairly eagerly determine that it can return Just the moment it sees any element at all.

Semigroups for folding