HORIZON HASKELLDocslts/ghc-9.10.x248f8f02026-10-05Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05

Modulegeneric-lens-2.2.2.0Haskell2010

Data.Generics.Internal.VL.Iso

Internal lens helpers. Only exported for Haddock

  • 3 types
  • 11 values
datadata Exchange a b s t
#

Constructors

  • Exchange (s -> a) (b -> t)
Instances2Profunctor, Functor
  • Profunctor (Exchange a b)Defined in generic-lens-2.2.2.0 · Data.Generics.Internal.VL.Iso
  • Functor (Exchange a b s)Defined in generic-lens-2.2.2.0 · Data.Generics.Internal.VL.Iso
valuefromIso :: Iso s t a b -> Iso b a t s
#
valueiso2isovl :: Iso s t a b -> Iso s t a b
#
valuewithIso :: Iso s t a b -> ((s -> a) -> (b -> t) -> r) -> r
#

Extract the two functions, one from s -> a and one from b -> t that characterize an Iso.

valuerepIso :: (Generic a, Generic b) => Iso a b (Rep a x) (Rep b x)
#

A type and its generic representation are isomorphic

valuerepIsoN :: (GenericN a, GenericN b) => Iso a b (RepN a x) (RepN b x)
#
valuemIso
  1. :: (Profunctor p2, Functor f2)
  2. => p2 (f1 p1) (f2 (g p1))
  3. -> p2 (M1 i c f1 p1) (f2 (M1 i c g p1))
#

M1 is just a wrapper around `f p`

valueiso :: (s -> a) -> (b -> t) -> Iso s t a b
#