X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=components%2Ftactics%2Fdeclarative.ml;h=94ef66c952509257b70371333a5f9d3c6c990bbb;hb=d738a2c22023d2f6df4c60faf4dd18eb1a8ad970;hp=fc8b175a273e04970d1af8dd2b32c97cb2ae5383;hpb=06b128f1107fd579a696b83b2f8255f83ab29a92;p=helm.git diff --git a/components/tactics/declarative.ml b/components/tactics/declarative.ml index fc8b175a2..94ef66c95 100644 --- a/components/tactics/declarative.ml +++ b/components/tactics/declarative.ml @@ -45,10 +45,10 @@ let suppose t id ty = (fun _ metasenv ugraph -> ty,metasenv,ugraph)) ;; -let by_term_we_proved ~dbd t ty id ty' = +let by_term_we_proved ~dbd ~universe t ty id ty' = let just = match t with - None -> Tactics.auto ~dbd ~params:[] (* da sistemare *) ~universe:Universe.empty + None -> Tactics.auto ~dbd ~params:[] ~universe | Some t -> Tactics.apply t in match id with @@ -77,10 +77,10 @@ let by_term_we_proved ~dbd t ty id ty' = ~continuations:[ continuation ; just ] ;; -let bydone ~dbd t = +let bydone ~dbd ~universe t = let just = match t with - None -> Tactics.auto ~dbd ~params:[] ~universe:Universe.empty + None -> Tactics.auto ~dbd ~params:[] ~universe | Some t -> Tactics.apply t in just @@ -134,7 +134,7 @@ let existselim t id1 t1 id2 t2 = let andelim = existselim;; -let rewritingstep ~dbd lhs rhs just conclude = +let rewritingstep ~dbd ~universe lhs rhs just conclude = let aux ((proof,goal) as status) = let (curi,metasenv,proofbo,proofty) = proof in let _,context,_ = CicUtil.lookup_meta goal metasenv in @@ -149,8 +149,7 @@ let rewritingstep ~dbd lhs rhs just conclude = let just = match just with None -> - Tactics.auto ~dbd - ~params:["paramodulation","1"; "timeout","3"] ~universe:Universe.empty + Tactics.auto ~dbd ~params:["paramodulation","1"; "timeout","3"] ~universe | Some just -> Tactics.apply just in match lhs with @@ -238,10 +237,12 @@ let case id ~params = let thesisbecomes t = let ty = None in - (*BUG here: missing check on t *) match ty with - None -> Tacticals.id_tac + None -> + Tactics.change ~pattern:(None,[],Some (Cic.Implicit (Some `Hole))) + (fun _ metasenv ugraph -> t,metasenv,ugraph) | Some ty -> + (*BUG here: missing check on t *) Tactics.change ~pattern:(None,[],Some (Cic.Implicit (Some `Hole))) (fun _ metasenv ugraph -> ty,metasenv,ugraph) ;;