HList-0.5.0.0: Heterogeneous lists

Safe HaskellNone
LanguageHaskell2010

Data.HList.Label6

Contents

Description

The HList library

(C) 2004, Oleg Kiselyov, Ralf Laemmel, Keean Schupke

Yet another model of labels.

Labels are promoted Strings or Integers GHC.TypeLits inside the Label. Needs ghc7.6 or higher.

See CommonMain#label6demo for an example.

Orphan instances

KnownNat x => ShowLabel Nat x Source # 

Methods

showLabel :: Label x l -> String Source #

KnownSymbol x => ShowLabel Symbol x Source # 

Methods

showLabel :: Label x l -> String Source #

HExtend (Label Nat y) (Proxy [Nat] ((:) Nat x xs)) Source # 

Associated Types

type HExtendR (Label Nat y) (Proxy [Nat] ((Nat ': x) xs)) :: * Source #

Methods

(.*.) :: Label Nat y -> Proxy [Nat] ((Nat ': x) xs) -> HExtendR (Label Nat y) (Proxy [Nat] ((Nat ': x) xs)) Source #

HExtend (Label Symbol y) (Proxy [Symbol] ((:) Symbol x xs)) Source #
>>> let labelX = Label :: Label "x"
>>> let labelY = Label :: Label "y"
>>> let p = labelX .*. labelY .*. emptyProxy
>>> :t p
p :: Proxy '["x", "y"]

Associated Types

type HExtendR (Label Symbol y) (Proxy [Symbol] ((Symbol ': x) xs)) :: * Source #

Methods

(.*.) :: Label Symbol y -> Proxy [Symbol] ((Symbol ': x) xs) -> HExtendR (Label Symbol y) (Proxy [Symbol] ((Symbol ': x) xs)) Source #