]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/software/components/cic_acic/cic2acic.ml
- new tactic applyP for use in the *P*rocedural script reconstruction
[helm.git] / helm / software / components / cic_acic / cic2acic.ml
index c5bbfff78b34d658e347e817d84c0857d8b0aae5..01a4bb144c306412dd9dc8a121b046673c16f91a 100644 (file)
 
 (* $Id$ *)
 
-type sort_kind = [ `Prop | `Set | `Type of CicUniv.universe | `CProp ]
+type sort_kind = [ `Prop | `Set | `Type of CicUniv.universe | `CProp of CicUniv.universe  ]
 
 let string_of_sort = function
   | `Prop -> "Prop"
   | `Set -> "Set"
-  | `Type u -> "Type:" ^ string_of_int (CicUniv.univno u)
-  | `CProp -> "CProp"
+  | `Type u -> "Type:" ^ string_of_int (CicUniv.univno u) ^ ":" ^ UriManager.string_of_uri (CicUniv.univuri u)
+  | `CProp u -> "CProp:" ^ string_of_int (CicUniv.univno u) ^ ":" ^ UriManager.string_of_uri (CicUniv.univuri u)
+
 
 let sort_of_sort = function
   | Cic.Prop  -> `Prop
   | Cic.Set   -> `Set
   | Cic.Type u -> `Type u
-  | Cic.CProp -> `CProp
+  | Cic.CProp u -> `CProp u
 
 (* let hashtbl_add_time = ref 0.0;; *)
 
@@ -49,11 +50,11 @@ let xxx_add h k v =
 let xxx_type_of_aux' m c t =
  let res,_ =
    try
-    CicTypeChecker.type_of_aux' m c t CicUniv.empty_ugraph
+    CicTypeChecker.type_of_aux' m c t CicUniv.oblivion_ugraph
    with
    | CicTypeChecker.AssertFailure _
    | CicTypeChecker.TypeCheckerFailure _ ->
-       Cic.Sort Cic.Prop, CicUniv.empty_ugraph
+       Cic.Sort Cic.Prop, CicUniv.oblivion_ugraph
   in
  res
 ;;
@@ -149,7 +150,7 @@ let acic_of_cic_context' ~computeinnertypes:global_computeinnertypes
         | C.Sort C.Set   -> `Set
         | C.Sort (C.Type u) -> `Type u
         | C.Meta _       -> `Type (CicUniv.fresh())
-        | C.Sort C.CProp -> `CProp
+        | C.Sort (C.CProp u) -> `CProp u
         | t              ->
             prerr_endline ("Cic2acic.sort_of applied to: " ^ CicPp.ppterm t) ;
             assert false