uniform-pair-0.1.4: Uniform pairs with class instances

Stabilityexperimental
Maintainerconal@conal.net
Safe HaskellSafe-Inferred

Data.UniformPair

Description

Uniform pairs. Because these pairs memoize functions (from Bool)--i.e., they're representable functors--these instances provided are fully determined by the corresponding instances for functions, thanks to the type class morphism principle.

Synopsis

Documentation

data Pair a Source

Uniform pairs

Constructors

a :# a 

fstP :: Pair a -> aSource

sndP :: Pair a -> aSource

firstP :: (a -> a) -> Pair a -> Pair aSource

secondP :: (a -> a) -> Pair a -> Pair aSource