X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fcomponents%2Fng_paramodulation%2FnCicParamod.ml;h=702cd8c16dc8c3482bdf64883e3b95b8de3efbbb;hb=926bd86002f91d2bf2a3ce7376309f5106268959;hp=f56ac0cdf270e0bd567d1987746ea60421fbee1b;hpb=e010714e36cd64e69e66d5e8f44c1229ec4deb61;p=helm.git diff --git a/matita/components/ng_paramodulation/nCicParamod.ml b/matita/components/ng_paramodulation/nCicParamod.ml index f56ac0cdf..702cd8c16 100644 --- a/matita/components/ng_paramodulation/nCicParamod.ml +++ b/matita/components/ng_paramodulation/nCicParamod.ml @@ -71,9 +71,9 @@ let nparamod status metasenv subst context t table = let context = context end in - let module B = B(C) in + (*let module B = B(C) in*) let module P = NCicParamod(C) in - let module Pp = Pp.Pp(B) in + (*let module Pp = Pp.Pp(B) in*) let bag, maxvar = Terms.empty_bag, 0 in let (bag,maxvar), goals = HExtlib.list_mapi_acc (fun x _ a -> P.mk_goal a x) (bag,maxvar) [t] @@ -132,20 +132,24 @@ let tooflex (_,l,_,_) = | _ -> false ;; -let forward_infer_step status metasenv subst context s t ty = +let forward_infer_step0 status metasenv subst context s t ty = let bag = P.bag_of_state s in let not_embed = let sty,_,_ = NCicMetaSubst.saturate status ~delta:0 metasenv subst context ty 0 in not_embeddable status subst context sty in - if not_embed then (debug (lazy "theorem not embeddable"); s) + if not_embed then (debug (lazy "theorem not embeddable"); s,None) else let bag,clause = P.mk_passive bag (t,ty) in if Terms.is_eq_clause clause then - if tooflex clause then (debug (lazy "pruning tooflex"); s) + if tooflex clause then (debug (lazy "pruning tooflex"); s,None) else - P.forward_infer_step (P.replace_bag s bag) clause 0 - else (debug (lazy "not eq"); s) + P.forward_infer_step (P.replace_bag s bag) clause 0, Some clause + else (debug (lazy "not eq"); s,None) +;; + +let forward_infer_step status metasenv subst context s t ty = + fst (forward_infer_step0 status metasenv subst context s t ty) ;; let index_obj status s uri = @@ -155,11 +159,11 @@ let index_obj status s uri = match obj with | (_,_,[],[],NCic.Constant(_,_,None,ty,_)) -> let nref = NReference.reference_of_spec uri NReference.Decl in - forward_infer_step status [] [] [] s (NCic.Const nref) ty + forward_infer_step0 status [] [] [] s (NCic.Const nref) ty | (_,d,[],[],NCic.Constant(_,_,Some(_),ty,_)) -> let nref = NReference.reference_of_spec uri (NReference.Def d) in - forward_infer_step status [] [] [] s (NCic.Const nref) ty - | _ -> s + forward_infer_step0 status [] [] [] s (NCic.Const nref) ty + | _ -> s,None ;; let demod status metasenv subst context s goal = @@ -201,7 +205,7 @@ let is_equation status metasenv subst context ty = NCicMetaSubst.saturate status ~delta:0 metasenv subst context ty 0 in match hty with - | NCic.Appl (eq ::tl) when eq = CB.eqP -> true + | NCic.Appl (eq ::_) when eq = CB.eqP -> true | _ -> false ;;