Idris2Doc : Deriving.SpecialiseData.Unification

Deriving.SpecialiseData.Unification

(source)
Facilities for constructor unification and using its results

Reexports

import public Data.DPair
import public Language.Reflection.Unify

Definitions

UniResults : Type
  Unification results for the whole type

Visibility: public export
mapCons : SpecTask -> ((pCon : Con) -> {auto 0 _ : ConArgsNamed pCon} -> r) -> List r
  Run monadic operation on all constructors of specialised type

Visibility: export
mapUCons : SpecTask -> (UnificationResult -> (pCon : Con) -> {auto 0 _ : ConArgsNamed pCon} -> Nat -> r) -> UniResults -> List r
  Map over all constructors for which unification succeeded

Visibility: export
map2UConsN : SpecTask -> (UnificationResult -> (mt : TypeInfo) -> {auto 0 _ : AllTyArgsNamed mt} -> (con : Con) -> {auto 0 _ : ConArgsNamed con} -> (mcon : Con) -> {auto 0 _ : ConArgsNamed mcon} -> ConMeta -> Nat -> r) -> UniResults -> (mt : TypeInfo) -> {auto 0 _ : AllTyArgsNamed mt} -> TypeMeta -> List r
  Run monadic operation on all pairs of specified and polymorphic constructors

Visibility: export
unifyCon : MonadLog m => CanUnify m => SpecTask -> (con : Con) -> {auto 0 _ : ConArgsNamed con} -> m UnificationVerdict
  Run unification for a given polymorphic constructor

Visibility: export