in
aux
-(* let find_appl_pattern_uris ap =
+let find_appl_pattern_uris ap =
let rec aux acc =
function
- | Ast.UriPattern uri ->
- (try
- ignore (List.find (fun uri' -> UriManager.eq uri uri') acc);
- acc
- with Not_found -> uri :: acc)
+ | Ast.UriPattern uri -> uri :: acc
| Ast.ImplicitPattern
| Ast.VarPattern _ -> acc
| Ast.ApplPattern apl -> List.fold_left aux acc apl
in
- aux [] ap *)
+ let uris = aux [] ap in
+ HExtlib.list_uniq (List.fast_sort UriManager.compare uris)
let rec find_branch =
function
val group: CicNotationPt.term list -> CicNotationPt.term
val ungroup: CicNotationPt.term list -> CicNotationPt.term list
-(* val find_appl_pattern_uris:
- CicNotationPt.cic_appl_pattern -> UriManager.uri list *)
+val find_appl_pattern_uris:
+ CicNotationPt.cic_appl_pattern -> UriManager.uri list
val find_branch:
CicNotationPt.term -> CicNotationPt.term