Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module defines operations to coerce
the type parameters of optics to
a representationally equal type. For example, if we have
newtype MkInt = MkInt Int
and
l :: Lens' S Int
then
coerceA @Int @MkInt l :: Lens' S MkInt
Documentation
coerceS :: Coercible s s' => Optic k is s t a b -> Optic k is s' t a b Source #
Lift coerce
to the s
parameter of an optic.
coerceT :: Coercible t t' => Optic k is s t a b -> Optic k is s t' a b Source #
Lift coerce
to the t
parameter of an optic.