X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Focaml%2Ftactics%2Fring.ml;h=ab7bde56f8dfa4049ca0989ccb55e64d3ac7eada;hb=7b78ae643999aa95b95b376fab54adb33dbed206;hp=4691239f411eb78362ce68dc29e839450675c6e2;hpb=31851952e1cc2db59168c5fd6f6093d9bc37ea86;p=helm.git diff --git a/helm/ocaml/tactics/ring.ml b/helm/ocaml/tactics/ring.ml index 4691239f4..ab7bde56f 100644 --- a/helm/ocaml/tactics/ring.ml +++ b/helm/ocaml/tactics/ring.ml @@ -34,11 +34,12 @@ open HelmLibraryObjects (** perform debugging output? *) let debug = false +let debug_print = fun _ -> () (** debugging print *) let warn s = if debug then - prerr_endline ("RING WARNING: " ^ s) + debug_print ("RING WARNING: " ^ s) (** CIC URIS *) @@ -436,9 +437,15 @@ let purge_hyps_tac ~count = match (n, context) with | (0, _) -> status | (n, hd::tl) -> - aux (n-1) tl - (status_of_single_goal_tactic_result - (ProofEngineTypes.apply_tactic (S.clear ~hyp:hd) status)) + let name_of_hyp = + match hd with + None + | Some (Cic.Anonymous,_) -> assert false + | Some (Cic.Name name,_) -> name + in + aux (n-1) tl + (status_of_single_goal_tactic_result + (ProofEngineTypes.apply_tactic (S.clear ~hyp:name_of_hyp) status)) | (_, []) -> failwith "Ring.purge_hyps_tac: no hypotheses left" in let (_, metasenv, _, _) = proof in