Mod_typingMain functions for translating module entries
type 'a vm_handler = {vm_handler : Environ.env ->
Declarations.universes ->
Constr.t ->
'a ->
'a * Vmlibrary.indirect_code;}type 'a vm_state = 'a * 'a vm_handlertranslate_module produces a module_body out of a module_entry. In the output fields:
mod_expr is Abstract for a MType entry, or Algebraic for MExpr.mod_type_alg is None only for a MExpr without explicit signature.The second component is the resolver an enclosing module type inherits from this declaration, or None if the module is a functor. It is the resolver of the module's type rather than of its body.
val translate_module :
('a, Conversion.graph_inconsistency) Conversion.universe_state ->
'b vm_state ->
Environ.env ->
Names.ModPath.t ->
Entries.inline ->
Entries.module_entry ->
(Mod_declarations.module_body
* Mod_subst.mod_type Mod_subst.delta_resolver option)
* 'a
* 'btranslate_modtype produces a module_type_body whose mod_type_alg cannot be None (and of course mod_expr is Abstract).
val translate_modtype :
('a, Conversion.graph_inconsistency) Conversion.universe_state ->
'b vm_state ->
Environ.env ->
Names.ModPath.t ->
Entries.inline ->
Entries.module_type_entry ->
Mod_declarations.module_type_body * 'a * 'bFrom an already-translated (or interactive) implementation and an (optional) signature entry, produces a final module_body
val finalize_module :
('a, Conversion.graph_inconsistency) Conversion.universe_state ->
'b vm_state ->
Environ.env ->
Names.ModPath.t ->
(Mod_declarations.module_signature
* Mod_subst.mod_type Mod_subst.delta_resolver) ->
(Entries.module_type_entry * Entries.inline) option ->
Mod_declarations.module_body * 'a * 'btranslate_mse_include is_mod state vmstate env mp self inl me translates the mse of a module or module type given to an Include.
val translate_mse_include :
bool ->
('a, Conversion.graph_inconsistency) Conversion.universe_state ->
'b vm_state ->
Environ.env ->
Names.ModPath.t ->
Mod_declarations.module_body ->
Entries.inline ->
Entries.module_struct_entry ->
Mod_declarations.structure_body
* Mod_subst.mod_type Mod_subst.delta_resolver
* 'a
* 'b