X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Fcic_disambiguation%2FdisambiguateTypes.ml;h=1eade4ca09850d1b6d6636d5b3bb8e203142e5ee;hb=424982ded255df68245241f56064202844ed1194;hp=79388f8198d3e20372a6f19c6ad17d55d0e0837a;hpb=8f9d476c32c48d14348a61889dc191c7696bd404;p=helm.git diff --git a/helm/software/components/cic_disambiguation/disambiguateTypes.ml b/helm/software/components/cic_disambiguation/disambiguateTypes.ml index 79388f819..1eade4ca0 100644 --- a/helm/software/components/cic_disambiguation/disambiguateTypes.ml +++ b/helm/software/components/cic_disambiguation/disambiguateTypes.ml @@ -40,7 +40,7 @@ type domain_item = | Symbol of string * int (* literal, instance num *) | Num of int (* instance num *) -exception Invalid_choice of string Lazy.t +exception Invalid_choice of Stdpp.location option * string Lazy.t module OrderedDomain = struct @@ -55,6 +55,16 @@ struct include Environment' + let find k env = + match k with + Symbol (sym,n) -> + (try find k env + with Not_found -> find (Symbol (sym,0)) env) + | Num n -> + (try find k env + with Not_found -> find (Num 0) env) + | _ -> find k env + let cons k v env = try let current = find k env in @@ -106,7 +116,7 @@ module type Callbacks = UriManager.uri list val interactive_interpretation_choice: string -> int -> - (Token.flocation list * string * string) list list -> int list + (Stdpp.location list * string * string) list list -> int list val input_or_locate_uri: title:string -> ?id:string -> unit -> UriManager.uri option end