Module Includemod.Error

type diff('elt, 'explanation) = {
  1. got: 'elt,
  2. expected: 'elt,
  3. symptom: 'explanation,
};
type core_diff('elt) = diff('elt, unit);
type functor_arg_descr =
  1. | Anonymous
  2. | Named(Path.t)
  3. | Unit
  4. | Empty_struct
    /*

    For backward compatibility's sake, an empty struct can be implicitly converted to an unit module.

    */
;
type core_module_type_symptom =
  1. | Not_an_alias
  2. | Not_an_identifier
  3. | Incompatible_aliases
  4. | Abstract_module_type
  5. | Unbound_module_path(Path.t)
;
type module_type_symptom =
  1. | Mt_core(core_module_type_symptom)
  2. | Signature(signature_symptom)
  3. | Functor(functor_symptom)
  4. | Invalid_module_alias(Path.t)
  5. | After_alias_expansion(module_type_diff)
;
and module_type_diff = diff(Types.module_type, module_type_symptom);
and functor_symptom =
  1. | Params(functor_params_diff)
  2. | Result(module_type_diff)
;
and functor_param_symptom('arg, 'path) =
  1. | Incompatible_params('arg, Types.functor_parameter)
  2. | Mismatch(module_type_diff)
;
and arg_functor_param_symptom = functor_param_symptom(Types.functor_parameter, Ident.t);
and functor_params_diff = core_diff((list(Types.functor_parameter), Types.module_type));
and signature_symptom = {
  1. env: Env.t,
  2. missings: list(Types.signature_item),
  3. incompatibles: list((Ident.t, sigitem_symptom)),
  4. oks: list((int, Typedtree.module_coercion)),
  5. leftovers: list((Types.signature_item as 'it, 'it, int)),
    /*

    signature items that could not be compared due to type divergence

    */
};
and sigitem_symptom =
  1. | Core(core_sigitem_symptom)
  2. | Module_type_declaration(diff(Types.modtype_declaration, module_type_declaration_symptom))
  3. | Module_type(module_type_diff)
;
and module_type_declaration_symptom =
  1. | Illegal_permutation(Typedtree.module_coercion)
  2. | Not_greater_than(module_type_diff)
  3. | Not_less_than(module_type_diff)
  4. | Incomparable of {
    1. less_than: module_type_diff,
    2. greater_than: module_type_diff,
    }
;
type all =
  1. | In_Compilation_unit(diff(string, signature_symptom))
  2. | In_Signature(signature_symptom)
  3. | In_Module_type(module_type_diff)
  4. | In_Module_type_substitution(Ident.t, diff(Types.module_type, module_type_declaration_symptom))
  5. | In_Type_declaration(Ident.t, core_sigitem_symptom)
  6. | In_Expansion(core_module_type_symptom)
;