]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/software/components/ng_kernel/rt.ml
added small test, fixed some bugs
[helm.git] / helm / software / components / ng_kernel / rt.ml
diff --git a/helm/software/components/ng_kernel/rt.ml b/helm/software/components/ng_kernel/rt.ml
new file mode 100644 (file)
index 0000000..74ed2ee
--- /dev/null
@@ -0,0 +1,17 @@
+let _ =
+  Helm_registry.load_from "conf.xml";
+  let u = UriManager.uri_of_string "cic:/matita/tests/f.con" in
+  let o, _ = CicEnvironment.get_obj CicUniv.oblivion_ugraph u in
+  let l = OCic2NCic.convert_obj u o in
+  let objs = 
+    List.flatten 
+    (List.map NCic2OCic.convert_nobj l) in
+  List.iter 
+   (fun (u,o) -> 
+     prerr_endline ("------- " ^ UriManager.string_of_uri u);
+     prerr_endline (CicPp.ppobj o);
+     try CicTypeChecker.typecheck_obj u o
+     with CicTypeChecker.TypeCheckerFailure s ->
+       prerr_endline (Lazy.force s)) 
+   objs;
+;;