aboutsummaryrefslogtreecommitdiffhomepage
path: root/contrib/xml/xmlcommand.ml
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/xml/xmlcommand.ml')
-rw-r--r--contrib/xml/xmlcommand.ml19
1 files changed, 10 insertions, 9 deletions
diff --git a/contrib/xml/xmlcommand.ml b/contrib/xml/xmlcommand.ml
index 573f4319b..5f23c1d64 100644
--- a/contrib/xml/xmlcommand.ml
+++ b/contrib/xml/xmlcommand.ml
@@ -305,15 +305,16 @@ let print_term inner_types l env csr =
(* coq coding of terms (the one of the logical framework) *)
match T.kind_of_term cstr with
T.IsRel n ->
- (match List.nth l (n - 1) with
- N.Name id ->
- X.xml_empty "REL"
- (add_sort_attribute false
- ["value",(string_of_int n) ;
- "binder",(N.string_of_id id) ;
- "id", next_id])
- | N.Anonymous -> assert false
- )
+ let id =
+ match List.nth l (n - 1) with
+ N.Name id -> id
+ | N.Anonymous -> N.make_ident "_" None
+ in
+ X.xml_empty "REL"
+ (add_sort_attribute false
+ ["value",(string_of_int n) ;
+ "binder",(N.string_of_id id) ;
+ "id", next_id])
| T.IsVar id ->
let depth =
match get_depth_of_var (N.string_of_id id) with