add k (v :: (List.filter (fun x -> desc_of_alias x <> dsc) current)) env
with Not_found ->
add k [v] env
-
- let hd list_env =
- try
- map List.hd list_env
- with Failure _ -> assert false
-
- let fold_flatten f env base =
- fold
- (fun k l acc -> List.fold_right (fun v acc -> f k v acc) l acc)
- env base
-
end
type 'term codomain_item =
[`Num_interp of string -> 'term
|`Sym_interp of 'term list -> 'term]
-and 'term environment = 'term codomain_item Environment.t
-
-type 'term multiple_environment =
- 'term codomain_item list Environment.t
-
type interactive_user_uri_choice_type =
selection_mode:[`SINGLE | `MULTIPLE] ->
?ok:string ->
type input_or_locate_uri_type =
title:string -> ?id:string -> unit -> UriManager.uri option
-module type Callbacks =
- sig
- val interactive_user_uri_choice : interactive_user_uri_choice_type
-
- val interactive_interpretation_choice :
- interactive_interpretation_choice_type
-
- val input_or_locate_uri: input_or_locate_uri_type
- end
-
let string_of_domain_item = function
| Id s -> Printf.sprintf "ID(%s)" s
| Symbol (s, i) -> Printf.sprintf "SYMBOL(%s,%d)" s i
| Num i -> Printf.sprintf "NUM(instance %d)" i
-
-let string_of_domain dom =
- String.concat "; " (List.map string_of_domain_item dom)