| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
open Genarg |
| 12 |
open Names |
| 13 |
open Libnames |
| 14 |
open Nametab |
| 15 |
open Tac2expr |
| 16 |
open Tac2val |
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
type global_data = { |
| 23 |
gdata_expr : glb_tacexpr; |
| 24 |
gdata_type : type_scheme; |
| 25 |
gdata_mutable : bool; |
| 26 |
gdata_deprecation : Deprecation.t option; |
| 27 |
gdata_mutation_history : ModPath.t list; |
| 28 |
} |
| 29 |
|
| 30 |
val define_global : ltac_constant -> global_data -> unit |
| 31 |
val interp_global : ltac_constant -> global_data |
| 32 |
|
| 33 |
type compile_info = { |
| 34 |
source : string; |
| 35 |
} |
| 36 |
|
| 37 |
val set_compiled_global : ltac_constant -> compile_info -> valexpr -> unit |
| 38 |
val get_compiled_global : ltac_constant -> (compile_info * valexpr) option |
| 39 |
|
| 40 |
val globals : unit -> global_data KerName.Map.t |
| 41 |
|
| 42 |
|
| 43 |
|
| 44 |
val define_type : type_constant -> glb_quant_typedef -> unit |
| 45 |
val interp_type : type_constant -> glb_quant_typedef |
| 46 |
|
| 47 |
|
| 48 |
|
| 49 |
type constructor_data = { |
| 50 |
cdata_prms : int; |
| 51 |
|
| 52 |
cdata_type : type_constant; |
| 53 |
|
| 54 |
cdata_args : int glb_typexpr list; |
| 55 |
|
| 56 |
cdata_indx : int option; |
| 57 |
|
| 58 |
|
| 59 |
|
| 60 |
|
| 61 |
} |
| 62 |
|
| 63 |
val define_constructor : ltac_constructor -> constructor_data -> unit |
| 64 |
val interp_constructor : ltac_constructor -> constructor_data |
| 65 |
|
| 66 |
val find_all_constructors_in_type : type_constant -> constructor_data KerName.Map.t |
| 67 |
|
| 68 |
|
| 69 |
|
| 70 |
|
| 71 |
type projection_data = { |
| 72 |
pdata_prms : int; |
| 73 |
|
| 74 |
pdata_type : type_constant; |
| 75 |
|
| 76 |
pdata_ptyp : int glb_typexpr; |
| 77 |
|
| 78 |
pdata_mutb : bool; |
| 79 |
|
| 80 |
pdata_indx : int; |
| 81 |
|
| 82 |
} |
| 83 |
|
| 84 |
val define_projection : ltac_projection -> projection_data -> unit |
| 85 |
val interp_projection : ltac_projection -> projection_data |
| 86 |
|
| 87 |
|
| 88 |
|
| 89 |
type alias_data = { |
| 90 |
alias_body : raw_tacexpr; |
| 91 |
alias_depr : Deprecation.t option; |
| 92 |
} |
| 93 |
|
| 94 |
val define_alias : ?deprecation:Deprecation.t -> ltac_constant -> raw_tacexpr -> unit |
| 95 |
val interp_alias : ltac_constant -> alias_data |
| 96 |
|
| 97 |
|
| 98 |
|
| 99 |
|
| 100 |
type notation_data = |
| 101 |
| UntypedNota of raw_tacexpr |
| 102 |
| TypedNota of { |
| 103 |
nota_prms : int; |
| 104 |
nota_argtys : int glb_typexpr Id.Map.t; |
| 105 |
nota_ty : int glb_typexpr; |
| 106 |
nota_body : glb_tacexpr; |
| 107 |
} |
| 108 |
|
| 109 |
val define_notation : ltac_notation -> notation_data -> unit |
| 110 |
val interp_notation : ltac_notation -> notation_data |
| 111 |
|
| 112 |
|
| 113 |
|
| 114 |
val push_ltac : visibility -> full_path -> tacref -> unit |
| 115 |
val locate_ltac : qualid -> tacref |
| 116 |
val locate_extended_all_ltac : qualid -> tacref list |
| 117 |
val shortest_qualid_of_ltac : ?loc:Loc.t -> ?force_short:bool -> Id.Set.t -> tacref -> qualid |
| 118 |
val path_of_ltac : tacref -> full_path |
| 119 |
|
| 120 |
val push_constructor : ?user_warns:UserWarn.t -> visibility -> full_path -> ltac_constructor -> unit |
| 121 |
val locate_constructor : qualid -> ltac_constructor |
| 122 |
val locate_extended_all_constructor : qualid -> ltac_constructor list |
| 123 |
val shortest_qualid_of_constructor : ltac_constructor -> qualid |
| 124 |
val path_of_constructor : ltac_constructor -> full_path |
| 125 |
|
| 126 |
val push_type : visibility -> full_path -> type_constant -> unit |
| 127 |
val locate_type : qualid -> type_constant |
| 128 |
val locate_extended_all_type : qualid -> type_constant list |
| 129 |
val shortest_qualid_of_type : ?loc:Loc.t -> type_constant -> qualid |
| 130 |
val path_of_type : type_constant -> full_path |
| 131 |
|
| 132 |
val push_projection : visibility -> full_path -> ltac_projection -> unit |
| 133 |
val locate_projection : qualid -> ltac_projection |
| 134 |
val locate_extended_all_projection : qualid -> ltac_projection list |
| 135 |
val shortest_qualid_of_projection : ltac_projection -> qualid |
| 136 |
|
| 137 |
|
| 138 |
|
| 139 |
|
| 140 |
|
| 141 |
|
| 142 |
val define_primitive : ml_tactic_name -> valexpr -> unit |
| 143 |
val interp_primitive : ml_tactic_name -> valexpr |
| 144 |
|
| 145 |
|
| 146 |
|
| 147 |
type 'a or_glb_tacexpr = |
| 148 |
| GlbVal of 'a |
| 149 |
| GlbTacexpr of glb_tacexpr |
| 150 |
|
| 151 |
type ('a, 'b, 'r) intern_fun = Genintern.glob_sign -> 'a -> 'b * 'r glb_typexpr |
| 152 |
|
| 153 |
type environment = { |
| 154 |
env_ist : valexpr Id.Map.t; |
| 155 |
} |
| 156 |
|
| 157 |
type ('a, 'b) ml_object = { |
| 158 |
ml_intern : 'r. ('a, 'b or_glb_tacexpr, 'r) intern_fun; |
| 159 |
ml_subst : Mod_subst.substitution -> 'b -> 'b; |
| 160 |
ml_interp : environment -> 'b -> valexpr Proofview.tactic; |
| 161 |
ml_print : Environ.env -> Evd.evar_map -> 'b -> Pp.t; |
| 162 |
ml_raw_print : Environ.env -> Evd.evar_map -> 'a -> Pp.t; |
| 163 |
} |
| 164 |
|
| 165 |
val define_ml_object : ('a, 'b) Tac2dyn.Arg.tag -> ('a, 'b) ml_object -> unit |
| 166 |
val interp_ml_object : ('a, 'b) Tac2dyn.Arg.tag -> ('a, 'b) ml_object |
| 167 |
|
| 168 |
|
| 169 |
|
| 170 |
val rocq_prefix : ModPath.t |
| 171 |
|
| 172 |
|
| 173 |
val coq_prefix : ModPath.t [@@ocaml.deprecated "(9.0) Use rocq_prefix"] |
| 174 |
|
| 175 |
|
| 176 |
val std_prefix : ModPath.t |
| 177 |
|
| 178 |
|
| 179 |
val ltac1_prefix : ModPath.t |
| 180 |
|
| 181 |
|
| 182 |
|
| 183 |
|
| 184 |
val wit_ltac2_constr : (raw_tacexpr, Id.Set.t * glb_tacexpr, Util.Empty.t) genarg_type |
| 185 |
|
| 186 |
|
| 187 |
val wit_ltac2_tac : (raw_tacexpr, glb_tacexpr, unit) genarg_type |
| 188 |
|
| 189 |
|
| 190 |
type var_quotation_kind = |
| 191 |
| ConstrVar |
| 192 |
| PretermVar |
| 193 |
| PatternVar |
| 194 |
| HypVar |
| 195 |
|
| 196 |
val wit_ltac2_var_quotation : (lident option * lident, var_quotation_kind * Id.t, Util.Empty.t) genarg_type |
| 197 |
|
| 198 |
|
| 199 |
|
| 200 |
|
| 201 |
|
| 202 |
val is_constructor_id : Id.t -> bool |
| 203 |
val is_constructor : qualid -> bool |