smash-lens-0.1.0.3: Optics for the `smash` library
Copyright(c) 2020-2022 Emily Pillmore
LicenseBSD-style
MaintainerEmily Pillmore <emilypi@cohomolo.gy>
StabilityExperimental
PortabilityFlexibleInstances, MPTC, Type Families, UndecideableInstances
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Can.Lens

Description

Prisms and Traversals for the Can datatype.

Synopsis

Isos

_CanIso :: Iso (Can a b) (Can c d) (Maybe a, Maybe b) (Maybe c, Maybe d) Source #

A Iso between a wedge coproduct and pointed coproduct.

Prisms

_Non :: Prism' (Can a b) () Source #

A Prism' selecting the Non constructor.

Note: cannot change type.

_One :: Prism' (Can a b) a Source #

A Prism' selecting the One constructor.

Note: cannot change type.

_Eno :: Prism' (Can a b) b Source #

A Prism' selecting the Eno constructor.

Note: cannot change type.

_Two :: Prism' (Can a b) (a, b) Source #

A Prism' selecting the Two constructor.

Note: cannot change type.

Traversals

oneing :: Traversal (Can a c) (Can b c) a b Source #

A Traversal of the first parameter, suitable for use with Control.Lens.

enoing :: Traversal (Can a b) (Can a c) b c Source #

A Traversal of the second parameter, suitable for use with Control.Lens.

twoed :: Traversal' (Can a b) (a, b) Source #

A Traversal of the pair, suitable for use with Control.Lens.

twoing :: Traversal (Can a a) (Can b b) a b Source #

A Traversal of the pair ala both, suitable for use with Control.Lens.

Orphan instances

(a ~ a', b ~ b') => Each (Can a a') (Can b b') a b Source # 
Instance details

Methods

each :: Traversal (Can a a') (Can b b') a b #