Idris2Doc : Data.DList

Data.DList

(source)
A module defining the dependent list and its interface

Definitions

dataDList : (a->Type) ->Lista->Type
  A dependent list
@ f the constructor of the types of elements
@ ts the partameters from which the types of the lists elements are
constructed

Totality: total
Visibility: public export
Constructors:
Nil : DListf []
  The empty dependent list
(::) : fx->DListfxs->DListf (x::xs)
  Prepends a dependently typed element to a dependent list

Hints:
DFoldable (flipDListxs)
DFunctor (flipDListxs)
(++) : DListfxs->DListfys->DListf (xs++ys)
  Concatenate two dependent lists

Visibility: public export
Fixity Declaration: infixr operator, level 7
length : DListfxs->Nat
  Return the length of a dependent list

Visibility: export
head : DListf (x::xs) ->fx
  The head of a dependent list

Visibility: export
tail : DListf (x::xs) ->DListfxs
  The tail of a dependent list

Visibility: export
split : DListf (xs++xs') -> (DListfxs, DListfxs')
  split a dependent list in two

Visibility: export
pushToParams : DList (f.g) ts->DListf (mapgts)
  Push a component of the element type constructor to the parameter list

Visibility: export
pullFromParams : DListf (mapgts) ->DList (f.g) ts
  Pull a component of the element type constructor from the parameter list

Visibility: export
dmap : (ax->bx) ->DListaxs->DListbxs
  Apply a function to every element of a dependent list

Visibility: export
undmap : (ax->b) ->DListaxs->Listb
  Turn a dependent list into a non-dependent one by applying a
dependency-removing function to its elements.

Visibility: export
dmapList : ((x : t) ->fx) -> (xs : Listt) ->DListfxs
  Apply a dependent function to every element of a list,
thus, generate a dependent list

Visibility: export
dmapList' : (0f : (a->b)) -> ((x : a) ->g (fx)) -> (xs : Lista) ->DListg (mapfxs)
  A more general version of `dmapList`, where the resulting list is dependent
on a list of parameters which is itself a mapping on the original list

Visibility: export
dtraverse : Monadf=> (ax->f (bx)) ->DListaxs->f (DListbxs)
  Dependent version of `traverse`.

Map each element of a dependent list to a computation, evaluate those
computations and combine the results.

Visibility: export
dtraverseList : Monadm=> ((x : a) ->m (gx)) -> (xs : Lista) ->m (DListgxs)
  Map each element of a list to a computation whose result type is dependent
on the element, evaluate those computations and combine the results.

Visibility: export
dfoldr : (elx->acc->acc) ->acc->DListelts->acc
  `foldr` version for dependent lists

Visibility: export
dfoldl : (acc->elx->acc) ->acc->DListelts->acc
  `foldl` version for dependent lists

Visibility: export
dunzipWith : (fx-> (gx, hx)) ->DListfxs-> (DListgxs, DListhxs)
  `unzipWith` for dependent lists

Visibility: export
dunzip : DList (\x=> (fx, gx)) xs-> (DListfxs, DListgxs)
  `unzip` for dependent lists

Visibility: export
dzipWith : (fx->gx->hx) ->DListfxs->DListgxs->DListhxs
  `zipWith` for dependent lists

Visibility: export
dzip : DListfxs->DListgxs->DList (\x=> (fx, gx)) xs
  `zip` for dependent lists

Visibility: export
unzipParamsWith : (a-> (y : b**fy)) ->Lista-> (ys : Listb**DListfys)
  Unzip a list to a dependent list and its parameter list, using a function
that returns a dependent pair

Visibility: export
unzipParams : List (x : a**fx) -> (xs : Lista**DListfxs)
  Unzip a list of dependent pairs
Returns a list of parameters and a list of the dependent elements

Visibility: export
zipParamsWith : ((y : b) ->fy->a) -> (ys : Listb**DListfys) ->Lista
  Zip a dependent list with its params, according to a zipping function

Visibility: export
zipParams : (ys : Listb**DListfys) ->List (y : b**fy)
  Zip a dependent list with its params

Visibility: export
unzipDSums : List (DSumfg) -> (Some (DListf), Some (DListg))
  Unzip a list of dependent sums

Visibility: export
zipToDSums : DListfxs->DListgxs->List (DSumfg)
  Zip two dependent lists into a list of dependent sums

Visibility: export
unzipDPairsWith : {0f : t->Type} -> (fx-> (gx, hx)) -> (dpairs : List (x : t**fx)) -> (DListg (mapfstdpairs), DListh (mapfstdpairs))
  Zip a list of dependent pairs with an un-zipping function

Visibility: export
unzipDPairs : (dpairs : List (x : t** (fx, gx))) -> (DListf (mapfstdpairs), DListg (mapfstdpairs))
  Zip a list of dependent pairs
(of pairs of elements dependent on a common parameter)

Visibility: export
zipToDPairsWith : {0h : t->Type} -> (fx->gx->hx) ->DListfxs->DListgxs->List (x : t**hx)
  Zip two dependent lists into a list of dependent pairs, according to a
zipping function

Visibility: export
zipToDPairs : DListfxs->DListgxs->List (x : t** (fx, gx))
  Zip two dependent lists into a list of dependent pairs
(of pairs of elements dependent on a common parameter)

Visibility: export