Frames-0.7.2: Data frames For working with tabular data files
Safe HaskellSafe-Inferred
LanguageHaskell2010

Frames.TypeLevel

Description

Helpers for working with type-level lists.

Synopsis

Documentation

type family AllAre a ts :: Constraint where ... Source #

Constraint that every element of a promoted list is equal to a particular type. That is, the list of types is a single type repeated some number of times.

Equations

AllAre a '[] = () 
AllAre a (t ': ts) = (t ~ a, AllAre a ts) 

type family ReplaceAll a xs where ... Source #

ReplaceAll x ys produces a type-level list of the same length as ys where each element is x. In other words, it replaces each element of ys with x. This would be map (const x) ys in value-level Haskell.

Equations

ReplaceAll a '[] = '[] 
ReplaceAll a (x ': xs) = a ': ReplaceAll a xs 

type family ReplaceAllSnd a (xs :: [(k1, k2)]) where ... Source #

Replace the second component of every tuple in a type-level list with a constant.

Equations

ReplaceAllSnd a '[] = '[] 
ReplaceAllSnd a ('(s, x) ': xs) = '(s, a) ': ReplaceAllSnd a xs