+let eq_class_of hdb t1 =
+ let eq_class =
+ if NDiscriminationTree.NCicIndexable.path_string_of t1 =
+ [Discrimination_tree.Variable]
+ then
+ [] (* if the trie is unable to handle the key, we skip the query since
+ it sould retulr the whole content of the trie *)
+ else
+ let candidates = EQDB.retrieve_unifiables (snd hdb#uhint_db) t1 in
+ let candidates = HintSet.elements candidates in
+ let candidates = List.sort (fun (x,_) (y,_) -> compare x y) candidates in
+ List.map snd candidates
+ in
+ debug(lazy("eq_class of: " ^ NCicPp.ppterm ~metasenv:[] ~context:[] ~subst:[]
+ t1 ^ " is\n" ^ String.concat "\n"
+ (List.map (NCicPp.ppterm ~subst:[] ~metasenv:[] ~context:[]) eq_class)));
+ eq_class
+;;
+