Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source
Source file predefined.ml
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845(*
* Copyright (c) 2014 Leo White <lpw25@cl.cam.ac.uk>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*)openLangopenNamesletpredefined_location=letpoint={Location_.line=1;column=0}in{Location_.file="predefined";start=point;end_=point}letempty_doc=[]letnullary_equation=letopenTypeDecl.Equationinletparams=[]inletprivate_=falseinletmanifest=Noneinletconstraints=[]in{params;private_;manifest;constraints}letcovariant_equation=letopenTypeDeclinletopenTypeDecl.Equationinletparams=[{desc=Var"'a";variance=SomePos;injectivity=true}]inletprivate_=falseinletmanifest=Noneinletconstraints=[]in{params;private_;manifest;constraints}letinvariant_equation=letopenTypeDeclinletopenTypeDecl.Equationinletparams=[{desc=Var"'a";variance=None;injectivity=true}]inletprivate_=falseinletmanifest=Noneinletconstraints=[]in{params;private_;manifest;constraints}letbool_identifier=`CoreType(TypeName.make_std"bool")letint_identifier=`CoreType(TypeName.make_std"int")letchar_identifier=`CoreType(TypeName.make_std"char")letbytes_identifier=`CoreType(TypeName.make_std"bytes")letstring_identifier=`CoreType(TypeName.make_std"string")letfloat_identifier=`CoreType(TypeName.make_std"float")letunit_identifier=`CoreType(TypeName.make_std"unit")letexn_identifier=`CoreType(TypeName.make_std"exn")letarray_identifier=`CoreType(TypeName.make_std"array")letlist_identifier=`CoreType(TypeName.make_std"list")letoption_identifier=`CoreType(TypeName.make_std"option")letint32_identifier=`CoreType(TypeName.make_std"int32")letint64_identifier=`CoreType(TypeName.make_std"int64")letnativeint_identifier=`CoreType(TypeName.make_std"nativeint")letlazy_t_identifier=`CoreType(TypeName.make_std"lazy_t")letextension_constructor_identifier=`CoreType(TypeName.make_std"extension_constructor")letfloatarray_identifier=`CoreType(TypeName.make_std"floatarray")letfalse_identifier=`Constructor(bool_identifier,ConstructorName.make_std"false")lettrue_identifier=`Constructor(bool_identifier,ConstructorName.make_std"true")letvoid_identifier=`Constructor(unit_identifier,ConstructorName.make_std"()")letnil_identifier=`Constructor(list_identifier,ConstructorName.make_std"([])")letcons_identifier=`Constructor(list_identifier,ConstructorName.make_std"(::)")letnone_identifier=`Constructor(option_identifier,ConstructorName.make_std"None")letsome_identifier=`Constructor(option_identifier,ConstructorName.make_std"Some")letmatch_failure_identifier=`CoreException(ExceptionName.make_std"Match_failure")letassert_failure_identifier=`CoreException(ExceptionName.make_std"Assert_failure")letinvalid_argument_identifier=`CoreException(ExceptionName.make_std"Invalid_argument")letfailure_identifier=`CoreException(ExceptionName.make_std"Failure")letnot_found_identifier=`CoreException(ExceptionName.make_std"Not_found")letout_of_memory_identifier=`CoreException(ExceptionName.make_std"Out_of_memory")letstack_overflow_identifier=`CoreException(ExceptionName.make_std"Stack_overflow")letsys_error_identifier=`CoreException(ExceptionName.make_std"Sys_error")letend_of_file_identifier=`CoreException(ExceptionName.make_std"End_of_file")letdivision_by_zero_identifier=`CoreException(ExceptionName.make_std"Division_by_zero")letsys_blocked_io_identifier=`CoreException(ExceptionName.make_std"Sys_blocked_io")letundefined_recursive_module_identifier=`CoreException(ExceptionName.make_std"Undefined_recursive_module")letcore_type_identifier=function|"int"->Someint_identifier|"char"->Somechar_identifier|"bytes"->Somebytes_identifier|"string"->Somestring_identifier|"float"->Somefloat_identifier|"bool"->Somebool_identifier|"unit"->Someunit_identifier|"exn"->Someexn_identifier|"array"->Somearray_identifier|"list"->Somelist_identifier|"option"->Someoption_identifier|"int32"->Someint32_identifier|"int64"->Someint64_identifier|"nativeint"->Somenativeint_identifier|"lazy_t"->Somelazy_t_identifier|"extension_constructor"->Someextension_constructor_identifier|"floatarray"->Somefloatarray_identifier|_->Noneletcore_exception_identifier=function|"Match_failure"->Somematch_failure_identifier|"Out_of_memory"->Someout_of_memory_identifier|"Invalid_argument"->Someinvalid_argument_identifier|"Failure"->Somefailure_identifier|"Not_found"->Somenot_found_identifier|"Sys_error"->Somesys_error_identifier|"End_of_file"->Someend_of_file_identifier|"Division_by_zero"->Somedivision_by_zero_identifier|"Stack_overflow"->Somestack_overflow_identifier|"Sys_blocked_io"->Somesys_blocked_io_identifier|"Assert_failure"->Someassert_failure_identifier|"Undefined_recursive_module"->Someundefined_recursive_module_identifier|_->Noneletcore_constructor_identifier=function|"false"->Somefalse_identifier|"true"->Sometrue_identifier|"()"->Somevoid_identifier|"[]"->Somenil_identifier|"([])"->Somenil_identifier|"::"->Somecons_identifier|"(::)"->Somecons_identifier|"None"->Somenone_identifier|"Some"->Somesome_identifier|_->Noneletbool_path=`Resolved(`Identifierbool_identifier)letint_path=`Resolved(`Identifierint_identifier)letchar_path=`Resolved(`Identifierchar_identifier)letbytes_path=`Resolved(`Identifierbytes_identifier)letstring_path=`Resolved(`Identifierstring_identifier)letfloat_path=`Resolved(`Identifierfloat_identifier)letunit_path=`Resolved(`Identifierunit_identifier)letexn_path=`Resolved(`Identifierexn_identifier)letarray_path=`Resolved(`Identifierarray_identifier)letlist_path=`Resolved(`Identifierlist_identifier)letoption_path=`Resolved(`Identifieroption_identifier)letint32_path=`Resolved(`Identifierint32_identifier)letint64_path=`Resolved(`Identifierint64_identifier)letnativeint_path=`Resolved(`Identifiernativeint_identifier)letlazy_t_path=`Resolved(`Identifierlazy_t_identifier)letextension_constructor_path=`Resolved(`Identifierextension_constructor_identifier)let_floatarray_path=`Resolved(`Identifierfloatarray_identifier)letbool_reference=`Resolved(`Identifierbool_identifier)letint_reference=`Resolved(`Identifierint_identifier)letchar_reference=`Resolved(`Identifierchar_identifier)letbytes_reference=`Resolved(`Identifierbytes_identifier)letstring_reference=`Resolved(`Identifierstring_identifier)letfloat_reference=`Resolved(`Identifierfloat_identifier)letunit_reference=`Resolved(`Identifierunit_identifier)letexn_reference=`Resolved(`Identifierexn_identifier)letarray_reference=`Resolved(`Identifierarray_identifier)letlist_reference=`Resolved(`Identifierlist_identifier)letoption_reference=`Resolved(`Identifieroption_identifier)letint32_reference=`Resolved(`Identifierint32_identifier)letint64_reference=`Resolved(`Identifierint64_identifier)letnativeint_reference=`Resolved(`Identifiernativeint_identifier)letlazy_t_reference=`Resolved(`Identifierlazy_t_identifier)letextension_constructor_reference=`Resolved(`Identifierextension_constructor_identifier)let_floatarray_reference=`Resolved(`Identifierfloatarray_identifier)letfalse_reference=`Resolved(`Identifierfalse_identifier)lettrue_reference=`Resolved(`Identifiertrue_identifier)letvoid_reference=`Resolved(`Identifiervoid_identifier)letnil_reference=`Resolved(`Identifiernil_identifier)letcons_reference=`Resolved(`Identifiercons_identifier)letnone_reference=`Resolved(`Identifiernone_identifier)letsome_reference=`Resolved(`Identifiersome_identifier)letmatch_failure_reference=`Resolved(`Identifiermatch_failure_identifier)letassert_failure_reference=`Resolved(`Identifierassert_failure_identifier)letinvalid_argument_reference=`Resolved(`Identifierinvalid_argument_identifier)letfailure_reference=`Resolved(`Identifierfailure_identifier)letnot_found_reference=`Resolved(`Identifiernot_found_identifier)letout_of_memory_reference=`Resolved(`Identifierout_of_memory_identifier)letstack_overflow_reference=`Resolved(`Identifierstack_overflow_identifier)letsys_error_reference=`Resolved(`Identifiersys_error_identifier)letend_of_file_reference=`Resolved(`Identifierend_of_file_identifier)letdivision_by_zero_reference=`Resolved(`Identifierdivision_by_zero_identifier)letsys_blocked_io_reference=`Resolved(`Identifiersys_blocked_io_identifier)letundefined_recursive_module_reference=`Resolved(`Identifierundefined_recursive_module_identifier)letfalse_decl=letopenTypeDecl.Constructorinletdoc=empty_docinletargs=Tuple[]inletres=Nonein{id=false_identifier;doc;args;res}lettrue_decl=letopenTypeDecl.Constructorinletdoc=empty_docinletargs=Tuple[]inletres=Nonein{id=true_identifier;doc;args;res}letvoid_decl=letopenTypeDecl.Constructorinletdoc=empty_docinletargs=Tuple[]inletres=Nonein{id=void_identifier;doc;args;res}letnil_decl=letopenTypeDecl.Constructorinletdoc=empty_docinletargs=Tuple[]inletres=Nonein{id=nil_identifier;doc;args;res}letcons_decl=letopenTypeDecl.Constructorinletdoc=empty_docinlethead=TypeExpr.Var"'a"inlettail=TypeExpr.(Constr(list_path,[head]))inletargs=Tuple[head;tail]inletres=Nonein{id=cons_identifier;doc;args;res}letnone_decl=letopenTypeDecl.Constructorinletdoc=empty_docinletargs=Tuple[]inletres=Nonein{id=none_identifier;doc;args;res}letsome_decl=letopenTypeDecl.Constructorinletdoc=empty_docinletvar=TypeExpr.Var"'a"inletargs=Tuple[var]inletres=Nonein{id=some_identifier;doc;args;res}letint_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=int_identifierin(* let text = [Raw "The type of integer numbers."] in *)(* TODO *)(* let text = [] in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letchar_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=char_identifierin(* let text = [Raw "The type of characters."] in *)(* let text = [] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letbytes_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=bytes_identifierin(* let text = [Raw "The type of (writable) byte sequences."] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letstring_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=string_identifierin(* let text = [Raw "The type of (read-only) character strings."] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letfloat_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=float_identifierin(* let text = [Raw "The type of floating-point numbers."] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letbool_decl=letopenTypeDeclinletopenRepresentationin(* let open Odoc_model.Comment in *)letid=bool_identifierin(* let text = [Raw "The type of booleans (truth values)."] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Some(Variant[false_decl;true_decl])inletcanonical=Nonein{id;doc;canonical;equation;representation}letunit_decl=letopenTypeDeclinletopenRepresentationin(* let open Odoc_model.Comment in *)letid=unit_identifierin(* let text = [Raw "The type of the unit value."] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Some(Variant[void_decl])inletcanonical=Nonein{id;doc;canonical;equation;representation}letexn_decl=letopenTypeDeclinletopenRepresentationin(* let open Odoc_model.Comment in *)letid=exn_identifierin(* let text = [Raw "The type of exception values."] in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=SomeExtensibleinletcanonical=Nonein{id;doc;canonical;equation;representation}letarray_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=array_identifierin(* let text =
[Raw "The type of arrays whose elements have type ";
Code "'a";
Raw "."]
in *)(* let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=invariant_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letlist_decl=letopenTypeDeclinletopenRepresentationin(* let open Odoc_model.Comment in *)letid=list_identifierin(* let text =
[Raw "The type of lists whose elements have type ";
Code "'a";
Raw "."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=covariant_equationinletrepresentation=Some(Variant[nil_decl;cons_decl])inletcanonical=Nonein{id;doc;canonical;equation;representation}letoption_decl=letopenTypeDeclinletopenRepresentationin(* let open Odoc_model.Comment in *)letid=option_identifierin(* let text =
[Raw "The type of optional values of type ";
Code "'a";
Raw "."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=covariant_equationinletrepresentation=Some(Variant[none_decl;some_decl])inletcanonical=Nonein{id;doc;canonical;equation;representation}letint32_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=int32_identifierin(* let text =
[Raw "The type of signed 32-bit integers. See the ";
Reference(Element(Root("Int32", TModule)), None);
Raw " module."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letint64_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=int64_identifierin(* let text =
[Raw "The type of signed 64-bit integers. See the ";
Reference(Element(Root("Int64", TModule)), None);
Raw " module."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letnativeint_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=nativeint_identifierin(* let text =
[Raw "The type of signed, platform-native integers (32 bits on \
32-bit processors, 64 bits on 64-bit processors). See the ";
Reference(Element(Root("Nativeint", TModule)), None);
Raw " module."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=nullary_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letlazy_t_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=lazy_t_identifierin(* let text =
[Raw "This type is used to implement the ";
Reference(Element(Root("Lazy", TModule)), None);
Raw " module. It should not be used directly."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=covariant_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letextension_constructor_decl=letopenTypeDeclin(* let open Odoc_model.Comment in *)letid=extension_constructor_identifierin(* let text =
[Raw "cf. ";
Reference(Element(Root("Obj", TModule)), None);
Raw " module. It should not be used directly."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletequation=covariant_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letfloatarray_decl=letopenTypeDeclinletid=floatarray_identifierinletwordsss=ss|>List.rev_map(funs->[`Space;`Words])|>List.flatten|>List.tl|>List.revinletdoc=[`Paragraph(words["This";"type";"is";"used";"to";"implement";"the"]@[`Space;`Reference(`Module(`Root("Array",`TModule),ModuleName.make_std"Floatarray"),[]);`Space;]@words["module.";"It";"should";"not";"be";"used";"directly."]|>List.map(Location_.atpredefined_location));]|>List.map(Location_.atpredefined_location)inletequation=covariant_equationinletrepresentation=Noneinletcanonical=Nonein{id;doc;canonical;equation;representation}letmatch_failure_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=match_failure_identifierin(* let text =
[Raw "Exception raised when none of the cases of a pattern matching apply. \
The arguments are the location of the ";
Code "match";
Raw " keyword in the source code (file name, line number, column number)."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletstring_expr=TypeExpr.Constr(string_path,[])inletint_expr=TypeExpr.Constr(int_path,[])inletargs=TypeDecl.Constructor.Tuple[TypeExpr.Tuple[string_expr;int_expr;int_expr]]inletres=Nonein{id;doc;args;res}letassert_failure_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=assert_failure_identifierin(* let text =
[Raw "Exception raised when and assertion fails. \
The arguments are the location of the ";
Code "assert";
Raw " keyword in the source code (file name, line number, column number)."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletstring_expr=TypeExpr.Constr(string_path,[])inletint_expr=TypeExpr.Constr(int_path,[])inletargs=TypeDecl.Constructor.Tuple[TypeExpr.Tuple[string_expr;int_expr;int_expr]]inletres=Nonein{id;doc;args;res}letinvalid_argument_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=invalid_argument_identifierin(* let text =
[Raw "Exception raised by library functions to signal that the given \
arguments do not make sense."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[TypeExpr.Constr(string_path,[])]inletres=Nonein{id;doc;args;res}letfailure_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=failure_identifierin(* let text =
[Raw "Exception raised by library functions to signal that they are \
undefined on the given arguments."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[TypeExpr.Constr(string_path,[])]inletres=Nonein{id;doc;args;res}letnot_found_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=not_found_identifierin(* let text =
[Raw "Exception raised by search functions when the desired object \
could not be found."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[]inletres=Nonein{id;doc;args;res}letout_of_memory_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=out_of_memory_identifierin(* let text =
[Raw "Exception raised by the garbage collector when there is \
insufficient memory to complete the computation."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[]inletres=Nonein{id;doc;args;res}(* TODO: Provide reference to the OCaml manual *)letstack_overflow_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=stack_overflow_identifierin(* let text =
[Raw "Exception raised by the bytecode interpreter when the evaluation \
stack reaches its maximal size. This often indicates infinite or \
excessively deep recursion in the user's program. (Not fully \
implemented by the native-code compiler; see section 11.5 of \
the OCaml manual.)"]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[]inletres=Nonein{id;doc;args;res}letsys_error_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=sys_error_identifierin(* let text =
[Raw "Exception raised by the input/output functions to report an \
operating system error."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[TypeExpr.Constr(string_path,[])]inletres=Nonein{id;doc;args;res}letend_of_file_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=end_of_file_identifierin(* let text =
[Raw "Exception raised by input functions to signal that the end of \
file has been reached."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[]inletres=Nonein{id;doc;args;res}letdivision_by_zero_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=division_by_zero_identifierin(* let text =
[Raw "Exception raised by integer division and remainder operations \
when their second argument is zero."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[]inletres=Nonein{id;doc;args;res}letsys_blocked_io_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=sys_blocked_io_identifierin(* let text =
[Raw "A special case of ";
Reference(Element sys_error_reference, None);
Raw " raised when no I/O is possible on a non-blocking I/O channel."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletargs=TypeDecl.Constructor.Tuple[]inletres=Nonein{id;doc;args;res}(* TODO: Provide reference to the OCaml manual *)letundefined_recursive_module_decl=letopenLang.Exceptionin(* let open Odoc_model.Comment in *)letid=undefined_recursive_module_identifierin(* let text =
[Raw "Exception raised when an ill-founded recursive module definition \
is evaluated. (See section 7.8 of the OCaml manual.) The arguments \
are the location of the definition in the source code \
(file name, line number, column number)."]
in
let doc = Ok {empty_doc with text} in *)letdoc=empty_docinletstring_expr=TypeExpr.Constr(string_path,[])inletint_expr=TypeExpr.Constr(int_path,[])inletargs=TypeDecl.Constructor.Tuple[TypeExpr.Tuple[string_expr;int_expr;int_expr]]inletres=Nonein{id;doc;args;res}letcore_types=[int_decl;char_decl;bytes_decl;string_decl;float_decl;bool_decl;unit_decl;exn_decl;array_decl;list_decl;option_decl;int32_decl;int64_decl;nativeint_decl;lazy_t_decl;extension_constructor_decl;floatarray_decl;]letcore_exceptions=[match_failure_decl;assert_failure_decl;invalid_argument_decl;failure_decl;not_found_decl;out_of_memory_decl;stack_overflow_decl;sys_error_decl;end_of_file_decl;division_by_zero_decl;sys_blocked_io_decl;undefined_recursive_module_decl;]