| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
open Names |
| 12 |
open Libnames |
| 13 |
open Miniml |
| 14 |
open Declarations |
| 15 |
|
| 16 |
module Refset' : CSig.USetS with type elt = global |
| 17 |
module Refmap' : CSig.UMapS with type key = global |
| 18 |
|
| 19 |
type t |
| 20 |
|
| 21 |
val safe_basename_of_global : t -> global -> Id.t |
| 22 |
|
| 23 |
val make_table : unit -> t |
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
val warning_axioms : t -> unit |
| 28 |
val warning_opaques : t -> bool -> unit |
| 29 |
val warning_ambiguous_name : ?loc:Loc.t -> qualid * ModPath.t * GlobRef.t -> unit |
| 30 |
val warning_id : string -> unit |
| 31 |
val error_axiom_scheme : ?loc:Loc.t -> global -> int -> 'a |
| 32 |
val error_constant : ?loc:Loc.t -> global -> 'a |
| 33 |
val error_inductive : ?loc:Loc.t -> global -> 'a |
| 34 |
val error_nb_cons : unit -> 'a |
| 35 |
val error_module_clash : ModPath.t -> ModPath.t -> 'a |
| 36 |
val error_no_module_expr : ModPath.t -> 'a |
| 37 |
val error_singleton_become_prop : inductive -> 'a |
| 38 |
val error_unknown_module : ?loc:Loc.t -> qualid -> 'a |
| 39 |
val error_scheme : unit -> 'a |
| 40 |
val error_not_visible : global -> 'a |
| 41 |
val error_MPfile_as_mod : ModPath.t -> bool -> 'a |
| 42 |
val check_inside_section : unit -> unit |
| 43 |
val check_loaded_modfile : ModPath.t -> unit |
| 44 |
val msg_of_implicit : kill_reason -> string |
| 45 |
val err_or_warn_remaining_implicit : kill_reason -> unit |
| 46 |
|
| 47 |
val info_file : string -> unit |
| 48 |
|
| 49 |
|
| 50 |
|
| 51 |
val occur_kn_in_ref : MutInd.t -> global -> bool |
| 52 |
val repr_of_r : global -> KerName.t |
| 53 |
val modpath_of_r : global -> ModPath.t |
| 54 |
val label_of_r : global -> Id.t |
| 55 |
val base_mp : ModPath.t -> ModPath.t |
| 56 |
val is_modfile : ModPath.t -> bool |
| 57 |
val string_of_modfile : t -> DirPath.t -> string |
| 58 |
val file_of_modfile : t -> DirPath.t -> string |
| 59 |
val is_toplevel : ModPath.t -> bool |
| 60 |
val at_toplevel : ModPath.t -> bool |
| 61 |
val mp_length : ModPath.t -> int |
| 62 |
val prefixes_mp : ModPath.t -> ModPath.Set.t |
| 63 |
val common_prefix_from_list : |
| 64 |
ModPath.t -> ModPath.t list -> ModPath.t option |
| 65 |
val get_nth_label_mp : int -> ModPath.t -> Id.t |
| 66 |
val labels_of_ref : global -> ModPath.t * Id.t list |
| 67 |
|
| 68 |
|
| 69 |
|
| 70 |
|
| 71 |
|
| 72 |
|
| 73 |
|
| 74 |
|
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
val add_typedef : t -> Constant.t -> InfvInst.t -> constant_body -> ml_type -> unit |
| 79 |
val lookup_typedef : t -> Constant.t -> InfvInst.t -> constant_body -> ml_type option |
| 80 |
|
| 81 |
val add_cst_type : t -> Constant.t -> InfvInst.t -> constant_body -> ml_schema -> unit |
| 82 |
val lookup_cst_type : t -> Constant.t -> InfvInst.t -> constant_body -> ml_schema option |
| 83 |
|
| 84 |
val add_ind : t -> MutInd.t -> InfvInst.t -> mutual_inductive_body -> ml_ind -> unit |
| 85 |
val lookup_ind : t -> MutInd.t -> InfvInst.t -> mutual_inductive_body -> ml_ind option |
| 86 |
|
| 87 |
val add_inductive_kind : t -> MutInd.t -> InfvInst.t -> inductive_kind -> unit |
| 88 |
val is_coinductive : t -> global -> bool |
| 89 |
val is_coinductive_type : t -> ml_type -> bool |
| 90 |
|
| 91 |
val get_record_fields : |
| 92 |
t -> global -> global option list |
| 93 |
val record_fields_of_type : t -> ml_type -> global option list |
| 94 |
|
| 95 |
val add_recursors : t -> Environ.env -> MutInd.t -> unit |
| 96 |
val is_recursor : t -> global -> bool |
| 97 |
|
| 98 |
val add_projection : t -> int -> Constant.t -> inductive -> unit |
| 99 |
val is_projection : t -> global -> bool |
| 100 |
|
| 101 |
val add_info_axiom : t -> global -> unit |
| 102 |
val remove_info_axiom : t -> global -> unit |
| 103 |
val add_log_axiom : t -> global-> unit |
| 104 |
val add_symbol : t -> global -> unit |
| 105 |
val add_symbol_rule : t -> global -> Id.t -> unit |
| 106 |
|
| 107 |
val add_opaque : t -> global -> unit |
| 108 |
val remove_opaque : t -> global -> unit |
| 109 |
|
| 110 |
|
| 111 |
|
| 112 |
val output_directory : unit -> string |
| 113 |
|
| 114 |
|
| 115 |
|
| 116 |
val access_opaque : unit -> bool |
| 117 |
|
| 118 |
|
| 119 |
|
| 120 |
val auto_inline : unit -> bool |
| 121 |
|
| 122 |
|
| 123 |
|
| 124 |
val type_expand : unit -> bool |
| 125 |
|
| 126 |
|
| 127 |
|
| 128 |
val keep_singleton : unit -> bool |
| 129 |
|
| 130 |
|
| 131 |
|
| 132 |
type opt_flag = |
| 133 |
{ opt_kill_dum : bool; |
| 134 |
opt_fix_fun : bool; |
| 135 |
opt_case_iot : bool; |
| 136 |
opt_case_idr : bool; |
| 137 |
opt_case_idg : bool; |
| 138 |
opt_case_cst : bool; |
| 139 |
opt_case_fun : bool; |
| 140 |
opt_case_app : bool; |
| 141 |
opt_let_app : bool; |
| 142 |
opt_lin_let : bool; |
| 143 |
opt_lin_beta : bool } |
| 144 |
|
| 145 |
val optims : unit -> opt_flag |
| 146 |
|
| 147 |
|
| 148 |
|
| 149 |
val conservative_types : unit -> bool |
| 150 |
|
| 151 |
|
| 152 |
|
| 153 |
val file_comment : unit -> string |
| 154 |
|
| 155 |
|
| 156 |
|
| 157 |
type lang = Ocaml | Haskell | Scheme | JSON |
| 158 |
val lang : unit -> lang |
| 159 |
|
| 160 |
|
| 161 |
|
| 162 |
val to_inline : global -> bool |
| 163 |
val to_keep : global -> bool |
| 164 |
|
| 165 |
|
| 166 |
|
| 167 |
val implicits_of_global : global -> Int.Set.t |
| 168 |
|
| 169 |
|
| 170 |
|
| 171 |
|
| 172 |
val type_scheme_nb_args_hook : (Environ.env -> Constr.t -> int) Hook.t |
| 173 |
|
| 174 |
val is_custom : global -> bool |
| 175 |
val is_inline_custom : global -> bool |
| 176 |
val is_foreign_custom : global -> bool |
| 177 |
val find_callback : global -> string option |
| 178 |
val find_custom : global -> string |
| 179 |
val find_type_custom : global -> string list * string |
| 180 |
|
| 181 |
val is_custom_match : ml_branch array -> bool |
| 182 |
val find_custom_match : ml_branch array -> string |
| 183 |
|
| 184 |
|
| 185 |
|
| 186 |
val extraction_language : lang -> unit |
| 187 |
val extraction_inline : bool -> qualid list -> unit |
| 188 |
val print_extraction_inline : unit -> Pp.t |
| 189 |
val print_extraction_foreign : unit -> Pp.t |
| 190 |
val print_extraction_callback : unit -> Pp.t |
| 191 |
val reset_extraction_inline : unit -> unit |
| 192 |
val reset_extraction_foreign : unit -> unit |
| 193 |
val reset_extraction_callback : unit -> unit |
| 194 |
val extract_callback : string option -> qualid -> unit |
| 195 |
val extract_constant_inline : |
| 196 |
bool -> qualid -> string list -> string -> unit |
| 197 |
val extract_constant_foreign : |
| 198 |
qualid -> string -> unit |
| 199 |
val extract_inductive : |
| 200 |
qualid -> string -> string list -> string option -> unit |
| 201 |
|
| 202 |
|
| 203 |
type int_or_id = ArgInt of int | ArgId of Id.t |
| 204 |
val extraction_implicit : qualid -> int_or_id list -> unit |
| 205 |
|
| 206 |
|
| 207 |
|
| 208 |
val extraction_blacklist : string list -> unit |
| 209 |
val reset_extraction_blacklist : unit -> unit |
| 210 |
val print_extraction_blacklist : unit -> Pp.t |
| 211 |
|
| 212 |
|
| 213 |
|