package coq
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=b1501d686c21836302191ae30f610cca57fb309214c126518ca009363ad2cd3c
doc/coq-core.tactics/Tacticals/New/index.html
Module Tacticals.New
Source
The tacticals in the module New
are the tactical of Ltac. Their semantics is an extension of the tacticals in this file for the multi-goal backtracking tactics. They do not have the same semantics as the similarly named tacticals in Proofview
. The tactical of Proofview
are used in the definition of the tacticals of Tacticals.New
, but they are more atomic. In particular Tacticals.New.tclORELSE
sees lack of progress as a failure, whereas Proofview.tclORELSE
doesn't. Additionally every tactic which can catch failure (tclOR
, tclORELSE
, tclTRY
, tclREPEAt
, etc…) are run into each goal independently (failures and backtracks are localised to a given goal).
catch_failerror e
fails and decreases the level if e
is an Ltac error with level more than 0. Otherwise succeeds.
Fail with a User_Error
containing the given message.
val tclORD :
unit Proofview.tactic ->
(unit -> unit Proofview.tactic) ->
unit Proofview.tactic
Like tclOR
but accepts a delayed tactic as a second argument in the form of a function which will be run only in case of backtracking.
val tclIFCATCH :
unit Proofview.tactic ->
(unit -> unit Proofview.tactic) ->
(unit -> unit Proofview.tactic) ->
unit Proofview.tactic
val tclTHENS3PARTS :
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic
tclTHENS3PARTS tac1 [|t1 ; ... ; tn|] tac2 [|t'1 ; ... ; t'm|] gls
applies the tactic tac1
to gls
then, applies t1
, ..., tn
to the first n
resulting subgoals, t'1
, ..., t'm
to the last m
subgoals and tac2
to the rest of the subgoals in the middle. Raises an error if the number of resulting subgoals is strictly less than n+m
val tclTHENSLASTn :
unit Proofview.tactic ->
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic
val tclTHENSFIRSTn :
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic ->
unit Proofview.tactic
val tclTHENFIRSTn :
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic
tclTHENFIRST tac1 tac2 gls
applies the tactic tac1
to gls
and tac2
to the first resulting subgoal
val tclTHENLASTn :
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic
tclMAP f [x1..xn]
builds (f x1);(f x2);...(f xn)
val tclIFTHENELSE :
unit Proofview.tactic ->
unit Proofview.tactic ->
unit Proofview.tactic ->
unit Proofview.tactic
val tclIFTHENSVELSE :
unit Proofview.tactic ->
unit Proofview.tactic array ->
unit Proofview.tactic ->
unit Proofview.tactic
val tclIFTHENTRYELSEMUST :
unit Proofview.tactic ->
unit Proofview.tactic ->
unit Proofview.tactic
val tclIFTHENFIRSTTRYELSEMUST :
unit Proofview.tactic ->
unit Proofview.tactic ->
unit Proofview.tactic
val tclDELAYEDWITHHOLES :
bool ->
'a Tactypes.delayed_open ->
('a -> unit Proofview.tactic) ->
unit Proofview.tactic
val tclMAPDELAYEDWITHHOLES :
bool ->
'a Tactypes.delayed_open list ->
('a -> unit Proofview.tactic) ->
unit Proofview.tactic
val ifOnHyp :
(Environ.env -> Evd.evar_map -> (Names.Id.t * EConstr.types) -> bool) ->
(Names.Id.t -> unit Proofview.tactic) ->
(Names.Id.t -> unit Proofview.tactic) ->
Names.Id.t ->
unit Proofview.tactic
val onLastDecl :
(EConstr.named_declaration -> unit Proofview.tactic) ->
unit Proofview.tactic
val onNLastHypsId :
int ->
(Names.Id.t list -> unit Proofview.tactic) ->
unit Proofview.tactic
val onNLastHyps :
int ->
(EConstr.constr list -> unit Proofview.tactic) ->
unit Proofview.tactic
val onNLastDecls :
int ->
(EConstr.named_context -> unit Proofview.tactic) ->
unit Proofview.tactic
val onHyps :
(Proofview.Goal.t -> EConstr.named_context) ->
(EConstr.named_context -> unit Proofview.tactic) ->
unit Proofview.tactic
val afterHyp :
Names.Id.t ->
(EConstr.named_context -> unit Proofview.tactic) ->
unit Proofview.tactic
val tryAllHypsAndConcl :
(Names.Id.t option -> unit Proofview.tactic) ->
unit Proofview.tactic
val onClause :
(Names.Id.t option -> unit Proofview.tactic) ->
Locus.clause ->
unit Proofview.tactic
val tclTYPEOFTHEN :
?refresh:bool ->
EConstr.constr ->
(Evd.evar_map -> EConstr.types -> unit Proofview.tactic) ->
unit Proofview.tactic
val tclSELECT :
?nosuchgoal:'a Proofview.tactic ->
Goal_select.t ->
'a Proofview.tactic ->
'a Proofview.tactic