From aa3cb91d9386af581da2ac215e94a1f1ef582139 Mon Sep 17 00:00:00 2001 From: Claudio Sacerdoti Coen Date: Tue, 23 Sep 2003 17:39:01 +0000 Subject: [PATCH] ProofEngine.goal := ==> set_proof_engine_goal --- helm/gTopLevel/gTopLevel.ml | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/helm/gTopLevel/gTopLevel.ml b/helm/gTopLevel/gTopLevel.ml index 7fe26ff59..103a894ee 100644 --- a/helm/gTopLevel/gTopLevel.ml +++ b/helm/gTopLevel/gTopLevel.ml @@ -593,6 +593,10 @@ let refresh_proof (output : TermViewer.proof_viewer) = prerr_endline ("Offending proof: " ^ CicPp.ppobj (Cic.CurrentProof ("questa",metasenv,bo,ty,[]))) ; flush stderr ; raise (InvokeTactics.RefreshProofException e) +let set_proof_engine_goal g = + ProofEngine.goal := g +;; + let refresh_goals ?(empty_notebook=true) notebook = try match !ProofEngine.goal with @@ -701,14 +705,13 @@ let load_unfinished_proof () = match CicParser.obj_of_xml prooffiletype (Some prooffile) with Cic.CurrentProof (_,metasenv,bo,ty,_) -> typecheck_loaded_proof metasenv bo ty ; - ProofEngine.set_proof - (Some (uri, metasenv, bo, ty)) ; - ProofEngine.goal := + ProofEngine.set_proof (Some (uri, metasenv, bo, ty)) ; + refresh_proof output ; + set_proof_engine_goal (match metasenv with [] -> None | (metano,_,_)::_ -> Some metano ) ; - refresh_proof output ; refresh_goals notebook ; output_html outputhtml ("

Current proof type loaded from " ^ @@ -1581,7 +1584,7 @@ prerr_endline ("######################## " ^ xxx) ; let _ = CicTypeChecker.type_of_aux' metasenv [] expr in ProofEngine.set_proof (Some (!get_uri (), (1,[],expr)::metasenv, Cic.Meta (1,[]), expr)) ; - ProofEngine.goal := Some 1 ; + set_proof_engine_goal (Some 1) ; refresh_goals notebook ; refresh_proof output ; !save_set_sensitive true ; @@ -1673,7 +1676,7 @@ let open_ () = in ProofEngine.set_proof (Some (uri, metasenv, bo, ty)) ; - ProofEngine.goal := None ; + set_proof_engine_goal None ; refresh_goals notebook ; refresh_proof output ; !save_set_sensitive true @@ -2652,7 +2655,7 @@ object(self) if not skip then try let (metano,setgoal,page) = List.nth !pages i in - ProofEngine.goal := Some metano ; + set_proof_engine_goal (Some metano) ; Lazy.force (page#compute) ; Lazy.force setgoal; if notify_hbugs_on_goal_change then -- 2.39.2