Abstract binding trees are a generic representation of terms over a given signature
record Argument : TypeA constructor's argument describes the kind of the variables that
will be bound in the subterm as well as the overall type of the
argument.
The argument `n` in `S n` is described by `MkArgument [] Nat`
The argument `b` in `\x. b` is described by `MkArgument [s] t`
MkArgument : List kind -> kind -> Argument.binders : Argument -> List kindbinders : Argument -> List kind.argType : Argument -> kindargType : Argument -> kind0 Signature : TypeA signature is a relation describing constructors.
Each constructor has a list of arguments and a return type.
data Term : Signature -> SnocList kind -> kind -> Typedata Args : Signature -> SnocList kind -> List Argument -> Typelift : (Elem s ctx -> Elem s ctx') -> Elem s (ctx :< t) -> Elem s (ctx' :< t)lifts : (bds : List kind) -> (Elem s ctx -> Elem s ctx') -> Elem s (ctx <>< bds) -> Elem s (ctx' <>< bds)rename : (Elem s ctx -> Elem s ctx') -> Term sig ctx s -> Term sig ctx' srenames : (Elem s ctx -> Elem s ctx') -> Args sig ctx args -> Args sig ctx' argsextend : (Elem s ctx -> Term sig ctx' s) -> Elem s (ctx :< t) -> Term sig (ctx' :< t) sextends : (bds : List kind) -> (Elem s ctx -> Term sig ctx' s) -> Elem s (ctx <>< bds) -> Term sig (ctx' <>< bds) ssubstitute : (Elem s ctx -> Term sig ctx' s) -> Term sig ctx s -> Term sig ctx' ssubstitutes : (Elem s ctx -> Term sig ctx' s) -> Args sig ctx args -> Args sig ctx' args