struct
let call_tactic tactic () =
- let savedproof = !ProofEngine.proof in
+ let savedproof = ProofEngine.get_proof () in
let savedgoal = !ProofEngine.goal in
begin
try
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of the " ^
"sequent: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals ()
| RefreshProofException e ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of the " ^
"proof: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals () ;
C.refresh_proof ()
| e ->
C.output_html
("<h1 color=\"red\">" ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal
end
let call_tactic_with_input tactic ?term () =
- let savedproof = !ProofEngine.proof in
+ let savedproof = ProofEngine.get_proof () in
let savedgoal = !ProofEngine.goal in
let uri,metasenv,bo,ty =
- match !ProofEngine.proof with
+ match ProofEngine.get_proof () with
None -> assert false
| Some (uri,metasenv,bo,ty) -> uri,metasenv,bo,ty
in
| Some t -> (C.term_editor ())#set_term t);
(C.term_editor ())#get_metasenv_and_term canonical_context metasenv
in
- ProofEngine.proof := Some (uri,metasenv',bo,ty) ;
+ ProofEngine.set_proof (Some (uri,metasenv',bo,ty)) ;
tactic expr ;
C.refresh_goals () ;
C.refresh_proof () ;
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of the " ^
"sequent: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals ()
| RefreshProofException e ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of the " ^
"proof: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals () ;
C.refresh_proof ()
| e ->
C.output_html
("<h1 color=\"red\">" ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal
let call_tactic_with_goal_input tactic () =
let module L = LogicalOperations in
let module G = Gdome in
- let savedproof = !ProofEngine.proof in
+ let savedproof = ProofEngine.get_proof () in
let savedgoal = !ProofEngine.goal in
match (C.sequent_viewer ())#get_selected_terms with
[term] ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of " ^
"the sequent: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals ()
| RefreshProofException e ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of " ^
"the proof: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals () ;
C.refresh_proof ()
| e ->
C.output_html
("<h1 color=\"red\">" ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
end
| [] ->
let call_tactic_with_goal_inputs tactic () =
let module L = LogicalOperations in
let module G = Gdome in
- let savedproof = !ProofEngine.proof in
+ let savedproof = ProofEngine.get_proof () in
let savedgoal = !ProofEngine.goal in
try
match (C.sequent_viewer ())#get_selected_terms with
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of the " ^
"sequent: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals ()
| RefreshProofException e ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of the " ^
"proof: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals () ;
C.refresh_proof ()
| e ->
C.output_html
("<h1 color=\"red\">" ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal
let call_tactic_with_input_and_goal_input tactic () =
let module L = LogicalOperations in
let module G = Gdome in
- let savedproof = !ProofEngine.proof in
+ let savedproof = ProofEngine.get_proof () in
let savedgoal = !ProofEngine.goal in
match (C.sequent_viewer ())#get_selected_terms with
[term] ->
begin
try
let uri,metasenv,bo,ty =
- match !ProofEngine.proof with
+ match ProofEngine.get_proof () with
None -> assert false
| Some (uri,metasenv,bo,ty) -> uri,metasenv,bo,ty
in
let (metasenv',expr) =
(C.term_editor ())#get_metasenv_and_term canonical_context metasenv
in
- ProofEngine.proof := Some (uri,metasenv',bo,ty) ;
+ ProofEngine.set_proof (Some (uri,metasenv',bo,ty)) ;
tactic ~goal_input:term ~input:expr ;
C.refresh_goals () ;
C.refresh_proof () ;
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of " ^
"the sequent: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals ()
| RefreshProofException e ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of " ^
"the proof: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals () ;
C.refresh_proof ()
| e ->
C.output_html
("<h1 color=\"red\">" ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
end
| [] ->
let call_tactic_with_hypothesis_input tactic () =
let module L = LogicalOperations in
let module G = Gdome in
- let savedproof = !ProofEngine.proof in
+ let savedproof = ProofEngine.get_proof () in
let savedgoal = !ProofEngine.goal in
match (C.sequent_viewer ())#get_selected_hypotheses with
[hypothesis] ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of " ^
"the sequent: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals ()
| RefreshProofException e ->
C.output_html
("<h1 color=\"red\">Exception raised during the refresh of " ^
"the proof: " ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
C.refresh_goals () ;
C.refresh_proof ()
| e ->
C.output_html
("<h1 color=\"red\">" ^ Printexc.to_string e ^ "</h1>") ;
- ProofEngine.proof := savedproof ;
+ ProofEngine.set_proof savedproof ;
ProofEngine.goal := savedgoal ;
end
| [] ->