Module Termutils


module Termutils: sig .. end
Utility functions for terms.

val iter_vars : (Term.variable -> unit) -> Term.term -> unit
iter_vars f term effects that f is applied to all variables in term. If a variable has multiple occurences in term, f may be called on each occurence.
val is_ground : Term.term -> bool
is_ground term returns true iff term contains no variables.
val is_nonvar : Term.term -> bool
is_nonvar term returns true iff term is not a variable.
val varnum : Term.term -> int
term is assumed to be term of shape Variable variable. The variable number of variable is returned.