1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556(************************************************************************)(* * The Rocq Prover / The Rocq Development Team *)(* v * Copyright INRIA, CNRS and contributors *)(* <O___,, * (see version control and CREDITS file for authors & dates) *)(* \VV/ **************************************************************)(* // * This file is distributed under the terms of the *)(* * GNU Lesser General Public License Version 2.1 *)(* * (see LICENSE file for the text of the license) *)(************************************************************************)(** Generic arguments based on Ltac. *)openGenargopenGeninterpopenTacexprletmake0?dynname=letwit=Genarg.make0nameinlet()=Geninterp.register_val0witdyninwitletwit_intropattern=make0"intropattern"(* To keep after deprecation phase but it will get a different parsing semantics (Tactic Notation and TACTIC EXTEND) in pltac.ml *)letwit_simple_intropattern=make0~dyn:(val_tag(topwitwit_intropattern))"simple_intropattern"letwit_quant_hyp=make0"quant_hyp"letwit_constr_with_bindings=make0"constr_with_bindings"letwit_open_constr_with_bindings=make0"open_constr_with_bindings"letwit_bindings=make0"bindings"letwit_quantified_hypothesis=wit_quant_hyp(* we can put ocaml closures (through geninterp vals) in tacvalues so no need to be marshallable *)typetacvalue=..letwit_tactic:(raw_tactic_expr,glob_tactic_expr,tacvalue)genarg_type=make0"tactic"letwit_ltac_in_term=GenConstr.create"ltac_in_term"letwit_ltac=Gentactic.make"ltac"letwit_destruction_arg=make0"destruction_arg"moduleInternal=structletdefined_tacvalue=reffalseletdefine_tacvalue(typea)()=assert(not!defined_tacvalue);defined_tacvalue:=true;letmoduleM=(structtypetacvalue+=Vofaend)inletof_vx=M.Vxinletto_v=function|M.Vx->x|_->assertfalseinof_v,to_vend