Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data An_Equality :: OpticKind
- type Equality s t a b = Optic An_Equality '[] s t a b
- type Equality' s a = Optic' An_Equality '[] s a
- vlEquality :: (forall p f. p a (f b) -> p s (f t)) -> Equality s t a b
- equality :: (s ~ a, t ~ b) => Equality s t a b
- simple :: Equality' a a
- withEq :: Optic An_Equality is s t a b -> ((s ~ a, t ~ b) => r) -> r
- data Identical (s :: *) (t :: *) (a :: *) (b :: *) where
- runEq :: Optic An_Equality is s t a b -> Identical s t a b
- module Optics.Optic
Documentation
data An_Equality :: OpticKind #
Tag for an equality.
Instances
type Equality s t a b = Optic An_Equality '[] s t a b #
Type synonym for a type-modifying equality.
type Equality' s a = Optic' An_Equality '[] s a #
Type synonym for a type-preserving equality.
vlEquality :: (forall p f. p a (f b) -> p s (f t)) -> Equality s t a b #
Build an equality from the van Laarhoven representation.
withEq :: Optic An_Equality is s t a b -> ((s ~ a, t ~ b) => r) -> r #
Substituting types with Equality
.
runEq :: Optic An_Equality is s t a b -> Identical s t a b #
Obtain a witness for an equality.
module Optics.Optic