lens-4.12.2: Lenses, Folds and Traversals

Copyright(C) 2012-2015 Edward Kmett
LicenseBSD-style (see the file LICENSE)
MaintainerEdward Kmett <ekmett@gmail.com>
Stabilityprovisional
Portabilitynon-portable
Safe HaskellSafe
LanguageHaskell98

Control.Lens.Internal.Getter

Description

 

Synopsis

Documentation

coerce :: (Contravariant f, Functor f) => f a -> f b Source

A Functor you can coerce ignores its argument, which it carries solely as a phantom type parameter.

By the Functor and Contravariant laws, an instance of both will necessarily satisfy:

id = fmap f = coerce = contramap g