Copyright | (c) Fumiaki Kinoshita 2018 |
---|---|

License | BSD3 |

Maintainer | Fumiaki Kinoshita <fumiexcel@gmail.com> |

Safe Haskell | Trustworthy |

Language | Haskell2010 |

## Synopsis

- type AllOf xs = Identity :* xs
- type OneOf xs = Identity :| xs
- (<%) :: x -> AllOf xs -> AllOf (x ': xs)
- pluck :: x ∈ xs => AllOf xs -> x
- bury :: x ∈ xs => x -> OneOf xs
- (<%|) :: (x -> r) -> (OneOf xs -> r) -> OneOf (x ': xs) -> r
- accessing :: (Coercible x a, x ∈ xs, Extensible f p t, ExtensibleConstr t Identity xs x) => (a -> x) -> Optic' p f (t Identity xs) a

# Documentation

(<%|) :: (x -> r) -> (OneOf xs -> r) -> OneOf (x ': xs) -> r infixr 1 Source #

Naive pattern matching for a plain value.

accessing :: (Coercible x a, x ∈ xs, Extensible f p t, ExtensibleConstr t Identity xs x) => (a -> x) -> Optic' p f (t Identity xs) a Source #

An accessor for newtype constructors.