X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fmatita%2FmatitacLib.ml;h=1f9dad80f7dbcf1815dbdf7123c6a7032a7e5945;hb=41be5e85a1103a5b14495bb487995a6a88e79c48;hp=b2c3e9a323070ca26c2c5c2aef159ce52d66ad8c;hpb=7b995596c8b11be95c430646227d01928cc71219;p=helm.git diff --git a/helm/matita/matitacLib.ml b/helm/matita/matitacLib.ml index b2c3e9a32..1f9dad80f 100644 --- a/helm/matita/matitacLib.ml +++ b/helm/matita/matitacLib.ml @@ -98,7 +98,7 @@ let rec interactive_loop () = let str = Ulexing.from_utf8_channel stdin in try run_script str - (MatitaEngine.eval_from_stream_greedy + (MatitaEngine.eval_from_stream ~prompt:true ~include_paths:(Helm_registry.get_list Helm_registry.string "matita.includes")) with @@ -123,7 +123,7 @@ let go () = CicEnvironment.set_trust (* environment trust *) (let trust = Helm_registry.get_bool "matita.environment_trust" in fun _ -> trust); - status := Some (ref (Lazy.force MatitaEngine.initial_status)); + status := Some (ref (MatitaSync.init ())); Sys.catch_break true; interactive_loop () @@ -131,7 +131,7 @@ let main ~mode = MatitaInit.initialize_all (); (* must be called after init since args are set by cmdline parsing *) let fname = fname () in - status := Some (ref (Lazy.force MatitaEngine.initial_status)); + status := Some (ref (MatitaSync.init ())); Sys.catch_break true; let origcb = HLog.get_log_callback () in let newcb tag s = @@ -154,11 +154,12 @@ let main ~mode = | "stdin" -> stdin | fname -> open_in fname) in let include_paths = - Helm_registry.get_list Helm_registry.string "matita.includes" - in - run_script is - (MatitaEngine.eval_from_stream ~include_paths - ~clean_baseuri:(not (Helm_registry.get_bool "matita.preserve"))); + Helm_registry.get_list Helm_registry.string "matita.includes" in + (try + run_script is + (MatitaEngine.eval_from_stream ~include_paths + ~clean_baseuri:(not (Helm_registry.get_bool "matita.preserve"))) + with End_of_file -> ()); let elapsed = Unix.time () -. time in let tm = Unix.gmtime elapsed in let sec =