aboutsummaryrefslogtreecommitdiffhomepage
path: root/tactics/tactics.ml
diff options
context:
space:
mode:
authorGravatar Emilio Jesus Gallego Arias <e+git@x80.org>2018-04-08 04:00:44 +0200
committerGravatar Emilio Jesus Gallego Arias <e+git@x80.org>2018-05-24 23:27:23 +0200
commit1f4beb7369a0462502b26476e8748f21cc92ef72 (patch)
tree6834b9ce39ca05787f38ac9f6ea3324b741e6cf3 /tactics/tactics.ml
parent520c96f3af069e0af3ceb94fac6a1d8eb895a0a3 (diff)
[tactics] Remove anonymous fix/cofix form.
We remove the `fix N / cofix N` forms from the tactic language. This way, these tactics don't depend anymore on the proof context, in particular on the proof name, which seems like a fragile practice. Apart from the concerns wrt maintenability of proof scripts, this also helps making the "proof state" functional; as we don't have to propagate the proof name to the tactic layer.
Diffstat (limited to 'tactics/tactics.ml')
-rw-r--r--tactics/tactics.ml26
1 files changed, 2 insertions, 24 deletions
diff --git a/tactics/tactics.ml b/tactics/tactics.ml
index 01351e249..a42e4b44b 100644
--- a/tactics/tactics.ml
+++ b/tactics/tactics.ml
@@ -563,20 +563,7 @@ let mutual_fix f n rest j = Proofview.Goal.enter begin fun gl ->
end
end
-let warning_nameless_fix =
- CWarnings.create ~name:"nameless-fix" ~category:"deprecated" Pp.(fun () ->
- str "fix/cofix without a name are deprecated, please use the named version.")
-
-let fix ido n = match ido with
- | None ->
- warning_nameless_fix ();
- Proofview.Goal.enter begin fun gl ->
- let name = Proof_global.get_current_proof_name () in
- let id = new_fresh_id Id.Set.empty name gl in
- mutual_fix id n [] 0
- end
- | Some id ->
- mutual_fix id n [] 0
+let fix id n = mutual_fix id n [] 0
let rec check_is_mutcoind env sigma cl =
let b = whd_all env sigma cl in
@@ -619,16 +606,7 @@ let mutual_cofix f others j = Proofview.Goal.enter begin fun gl ->
end
end
-let cofix ido = match ido with
- | None ->
- warning_nameless_fix ();
- Proofview.Goal.enter begin fun gl ->
- let name = Proof_global.get_current_proof_name () in
- let id = new_fresh_id Id.Set.empty name gl in
- mutual_cofix id [] 0
- end
- | Some id ->
- mutual_cofix id [] 0
+let cofix id = mutual_cofix id [] 0
(**************************************************************)
(* Reduction and conversion tactics *)