X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Flibrary%2FlibrarySync.ml;h=d70bd15453cea4b9562d7abf94db97d21eaf94ef;hb=ed5c4e15429c37bef0f59dfd7160f6883586ed0f;hp=8a0c2bcc4406f8832a2fbe0e6fac5300ee4232ba;hpb=481ad7e9dbc461e8f1b4a71aa85fa83500173329;p=helm.git diff --git a/helm/software/components/library/librarySync.ml b/helm/software/components/library/librarySync.ml index 8a0c2bcc4..d70bd1545 100644 --- a/helm/software/components/library/librarySync.ml +++ b/helm/software/components/library/librarySync.ml @@ -128,8 +128,7 @@ let save_object_to_disk uri obj ugraph univlist = let typecheck_obj = let profiler = HExtlib.profile "add_obj.typecheck_obj" in - fun uri obj -> profiler.HExtlib.profile (CicTypeChecker.typecheck_obj uri) - (Unshare.fresh_types obj) + fun uri obj -> profiler.HExtlib.profile (CicTypeChecker.typecheck_obj uri) obj let index_obj = let profiler = HExtlib.profile "add_obj.index_obj" in @@ -160,8 +159,10 @@ let add_single_obj uri obj refinement_toolkit = (Printf.sprintf "QED: %%univ = %2.5f, total = %2.5f, univ = %2.5f, %s\n" (univ_time *. 100. /. total_time) (total_time) (univ_time) (UriManager.name_of_uri uri));*) - let _, ugraph, univlist = - CicEnvironment.get_cooked_obj_with_univlist CicUniv.empty_ugraph uri in + let obj, ugraph, univlist = + try CicEnvironment.get_cooked_obj_with_univlist CicUniv.empty_ugraph uri + with CicEnvironment.Object_not_found _ -> assert false + in try index_obj ~dbd ~uri; (* 2 must be in the env *) try @@ -229,7 +230,7 @@ let generate_elimination_principles uri refinement_toolkit = List.iter remove_single_obj !uris; raise exn in - let (obj, univ) = (CicEnvironment.get_obj CicUniv.empty_ugraph uri) in + let obj, _ = (CicEnvironment.get_obj CicUniv.oblivion_ugraph uri) in match obj with | Cic.InductiveDefinition (indTypes, _, _, _) -> let counter = ref 0 in @@ -273,7 +274,7 @@ let add_coercion ~add_composites refinement_toolkit uri arity saturations = let coer_ty,_ = let coer = CicUtil.term_of_uri uri in - CicTypeChecker.type_of_aux' [] [] coer CicUniv.empty_ugraph + CicTypeChecker.type_of_aux' [] [] coer CicUniv.oblivion_ugraph in (* we have to get the source and the tgt type uri * in Coq syntax we have already their names, but @@ -420,8 +421,8 @@ let generate_projections refinement_toolkit uri fields = (fun (uri, name, bo) (_name, coercion, arity) -> let saturations = 0 in try - let ty, ugraph = - CicTypeChecker.type_of_aux' [] [] bo CicUniv.empty_ugraph in + let ty, _ = + CicTypeChecker.type_of_aux' [] [] bo CicUniv.oblivion_ugraph in let attrs = [`Class `Projection; `Generated] in let obj = Cic.Constant (name,Some bo,ty,[],attrs) in add_single_obj uri obj refinement_toolkit;