search_top_down : (term -> term -> ((term # term) list # (type # type) list) list)
The length of the returned list indicates the number of matches found. An empty list means no match can be found between tm1 and tm2 or any subterms of tm2. The instantiations returned in the list are in the same format as for the function match. Each instantiation is a pair of lists: the first is a list of term pairs and the second is a list of type pairs. Either of these lists may be empty. The situation in which both lists are empty indicates that there is an exact match between the two terms, i.e., no instantiation is required to make the entire tm2 or a part of tm2 the same as tm1.
#search_top_down "x = y:*" "3 = 5";; [([("5", "y"); ("3", "x")], [(":num", ":*")])] : ((term # term) list # (type # type) list) list #search_top_down "x = y:*" "x =y:*";; [([], [])] : ((term # term) list # (type # type) list) list #search_top_down "x = y:*" "0 < p ==> (x <= p = y <= p)";; [([("y <= p", "y"); ("x <= p", "x")], [(":bool", ":*")])] : ((term # term) list # (type # type) list) list