X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Ftactics%2FproofEngineTypes.ml;h=93436e799586b899ecd4ffe6a7ebb098e8e3f5b0;hb=eaf5880ed69963b3ad37cb1f8a1fd48b2918e58b;hp=eb48ff3e8d86902f8e114ab73f0b2d3af959e39f;hpb=61a2faa2694907757dd617175e0144705e79d65a;p=helm.git diff --git a/helm/software/components/tactics/proofEngineTypes.ml b/helm/software/components/tactics/proofEngineTypes.ml index eb48ff3e8..93436e799 100644 --- a/helm/software/components/tactics/proofEngineTypes.ml +++ b/helm/software/components/tactics/proofEngineTypes.ml @@ -28,7 +28,7 @@ (** current proof (proof uri * metas * (in)complete proof * term to be prooved) *) -type proof = UriManager.uri option * Cic.metasenv * Cic.term * Cic.term * Cic.attribute list +type proof = UriManager.uri option * Cic.metasenv * Cic.substitution * Cic.term * Cic.term * Cic.attribute list (** current goal, integer index *) type goal = int type status = proof * goal @@ -43,8 +43,9 @@ let initial_status ty metasenv attrs = aux max tl in let newmeta_idx = aux 0 metasenv in + let _subst = [] in let proof = - None, (newmeta_idx, [], ty) :: metasenv, Cic.Meta (newmeta_idx, []), ty, attrs + None, (newmeta_idx, [], ty) :: metasenv, _subst, Cic.Meta (newmeta_idx, []), ty, attrs in (proof, newmeta_idx) @@ -75,13 +76,15 @@ type ('term, 'lazy_term) pattern = type lazy_pattern = (Cic.term, Cic.lazy_term) pattern +let hole = Cic.Implicit (Some `Hole) + let conclusion_pattern t = let t' = match t with | None -> None | Some t -> Some (const_lazy_term t) in - t',[],Some (Cic.Implicit (Some `Hole)) + t',[], Some hole (** tactic failure *) exception Fail of string Lazy.t @@ -90,13 +93,13 @@ exception Fail of string Lazy.t calls the opaque tactic on the status *) let apply_tactic t status = - let (uri,metasenv,bo,ty, attrs), gl = t status in + let (uri,metasenv,subst,bo,ty, attrs), gl = t status in match CicRefine.pack_coercion_obj (Cic.CurrentProof ("",metasenv,Cic.Rel ~-1,ty,[],attrs)) with | Cic.CurrentProof (_,metasenv,_,ty,_, attrs) -> - (uri,metasenv,bo,ty, attrs), gl + (uri,metasenv,subst,bo,ty, attrs), gl | _ -> assert false ;; @@ -104,5 +107,5 @@ let apply_tactic t status = type mk_fresh_name_type = Cic.metasenv -> Cic.context -> Cic.name -> typ:Cic.term -> Cic.name -let goals_of_proof (_,metasenv,_,_,_) = List.map (fun (g,_,_) -> g) metasenv +let goals_of_proof (_,metasenv,_subst,_,_,_) = List.map (fun (g,_,_) -> g) metasenv