ouroboros-consensus-0.1.0.1: Consensus layer for the Ouroboros blockchain protocol
Safe Haskell None
Language Haskell2010

Ouroboros.Consensus.HardFork.Combinator.Util.Tails

Synopsis

Documentation

data Tails (f :: k -> k -> Type ) (xs :: [k]) where Source #

For every tail (x ': xs) of the list, an f x y for every y in xs

Constructors

TNil :: Tails f '[]
TCons :: NP (f x) xs -> Tails f xs -> Tails f (x ': xs)

Convenience constructors

mk2 :: f x y -> Tails f '[x, y] Source #

mk3 :: f x y -> f x z -> f y z -> Tails f '[x, y, z] Source #

SOP-like operators

hcmap :: forall proxy c f g xs. All c xs => proxy c -> ( forall x y. (c x, c y) => f x y -> g x y) -> Tails f xs -> Tails g xs Source #

hcpure :: forall proxy f c xs. All c xs => proxy c -> ( forall x y. (c x, c y) => f x y) -> Tails f xs Source #

hmap :: SListI xs => ( forall x y. f x y -> g x y) -> Tails f xs -> Tails g xs Source #

hpure :: SListI xs => ( forall x y. f x y) -> Tails f xs Source #