extensible-0.5: Extensible, efficient, optics-friendly data types and effects

Copyright(c) Fumiaki Kinoshita 2018
LicenseBSD3
MaintainerFumiaki Kinoshita <fumiexcel@gmail.com>
Safe HaskellTrustworthy
LanguageHaskell2010

Data.Extensible.HList

Description

Heterogeneous list

Documentation

data HList (h :: k -> *) (xs :: [k]) where Source #

Constructors

HNil :: HList h '[] 
HCons :: h x -> HList h xs -> HList h (x ': xs) infixr 5 

htraverse :: Applicative f => (forall x. g x -> f (h x)) -> HList g xs -> f (HList h xs) Source #

htraverseWithIndex :: forall f g h xs. Applicative f => (forall x. Membership xs x -> g x -> f (h x)) -> HList g xs -> f (HList h xs) Source #

hfoldrWithIndex :: forall h r xs. (forall x. Membership xs x -> h x -> r -> r) -> r -> HList h xs -> r Source #

hlength :: HList h xs -> Int Source #