man-pages/man3/Parsetree.3o.html
2021-03-31 01:06:50 +01:00

2037 lines
26 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of Parsetree</TITLE>
</HEAD><BODY>
<H1>Parsetree</H1>
Section: OCaml library (3o)<BR>Updated: 2020-01-30<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
<H2>NAME</H2>
Parsetree - Abstract syntax tree produced by parsing
<A NAME="lbAC">&nbsp;</A>
<H2>Module</H2>
Module Parsetree
<A NAME="lbAD">&nbsp;</A>
<H2>Documentation</H2>
<P>
Module
<B>Parsetree</B>
<BR>&nbsp;:&nbsp;
<B>sig end</B>
<P>
<P>
Abstract syntax tree produced by parsing
<P>
Warning: this module is unstable and part of
<B>Compiler_libs</B>
.
<P>
<P>
<P>
<P>
<P>
<I>type constant </I>
=
<BR>&nbsp;|&nbsp;Pconst_integer
<B>of </B>
<B>string * char option</B>
<BR>&nbsp;|&nbsp;Pconst_char
<B>of </B>
<B>char</B>
<BR>&nbsp;|&nbsp;Pconst_string
<B>of </B>
<B>string * string option</B>
<BR>&nbsp;|&nbsp;Pconst_float
<B>of </B>
<B>string * char option</B>
<BR>&nbsp;
<P>
<P>
<P>
<P>
<P>
<A NAME="lbAE">&nbsp;</A>
<H3>Extension points</H3>
<P>
<P>
<I>type attribute </I>
= {
<BR>&nbsp;attr_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;attr_payload&nbsp;:&nbsp;
<B>payload</B>
;
<BR>&nbsp;attr_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type extension </I>
=
<B>string Asttypes.loc * payload</B>
<P>
<P>
<P>
<P>
<I>type attributes </I>
=
<B>attribute list</B>
<P>
<P>
<P>
<P>
<I>type payload </I>
=
<BR>&nbsp;|&nbsp;PStr
<B>of </B>
<B>structure</B>
<BR>&nbsp;|&nbsp;PSig
<B>of </B>
<B>signature</B>
<BR>&nbsp;|&nbsp;PTyp
<B>of </B>
<B>core_type</B>
<BR>&nbsp;|&nbsp;PPat
<B>of </B>
<B>pattern * expression option</B>
<BR>&nbsp;
<P>
<P>
<P>
<P>
<P>
<A NAME="lbAF">&nbsp;</A>
<H3>Core language</H3>
<P>
<P>
<I>type core_type </I>
= {
<BR>&nbsp;ptyp_desc&nbsp;:&nbsp;
<B>core_type_desc</B>
;
<BR>&nbsp;ptyp_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;ptyp_loc_stack&nbsp;:&nbsp;
<B>Location.t list</B>
;
<BR>&nbsp;ptyp_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type core_type_desc </I>
=
<BR>&nbsp;|&nbsp;Ptyp_any
<BR>&nbsp;|&nbsp;Ptyp_var
<B>of </B>
<B>string</B>
<BR>&nbsp;|&nbsp;Ptyp_arrow
<B>of </B>
<B>Asttypes.arg_label * core_type * core_type</B>
<BR>&nbsp;|&nbsp;Ptyp_tuple
<B>of </B>
<B>core_type list</B>
<BR>&nbsp;|&nbsp;Ptyp_constr
<B>of </B>
<B>Longident.t Asttypes.loc * core_type list</B>
<BR>&nbsp;|&nbsp;Ptyp_object
<B>of </B>
<B>object_field list * Asttypes.closed_flag</B>
<BR>&nbsp;|&nbsp;Ptyp_class
<B>of </B>
<B>Longident.t Asttypes.loc * core_type list</B>
<BR>&nbsp;|&nbsp;Ptyp_alias
<B>of </B>
<B>core_type * string</B>
<BR>&nbsp;|&nbsp;Ptyp_variant
<B>of </B>
<B>row_field list * Asttypes.closed_flag * Asttypes.label list option</B>
<BR>&nbsp;|&nbsp;Ptyp_poly
<B>of </B>
<B>string Asttypes.loc list * core_type</B>
<BR>&nbsp;|&nbsp;Ptyp_package
<B>of </B>
<B>package_type</B>
<BR>&nbsp;|&nbsp;Ptyp_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type package_type </I>
=
<B>Longident.t Asttypes.loc *</B>
<B>(Longident.t Asttypes.loc * core_type) list</B>
<P>
<P>
<P>
<P>
<I>type row_field </I>
= {
<BR>&nbsp;prf_desc&nbsp;:&nbsp;
<B>row_field_desc</B>
;
<BR>&nbsp;prf_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;prf_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type row_field_desc </I>
=
<BR>&nbsp;|&nbsp;Rtag
<B>of </B>
<B>Asttypes.label Asttypes.loc * bool * core_type list</B>
<BR>&nbsp;|&nbsp;Rinherit
<B>of </B>
<B>core_type</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type object_field </I>
= {
<BR>&nbsp;pof_desc&nbsp;:&nbsp;
<B>object_field_desc</B>
;
<BR>&nbsp;pof_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pof_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type object_field_desc </I>
=
<BR>&nbsp;|&nbsp;Otag
<B>of </B>
<B>Asttypes.label Asttypes.loc * core_type</B>
<BR>&nbsp;|&nbsp;Oinherit
<B>of </B>
<B>core_type</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type pattern </I>
= {
<BR>&nbsp;ppat_desc&nbsp;:&nbsp;
<B>pattern_desc</B>
;
<BR>&nbsp;ppat_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;ppat_loc_stack&nbsp;:&nbsp;
<B>Location.t list</B>
;
<BR>&nbsp;ppat_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type pattern_desc </I>
=
<BR>&nbsp;|&nbsp;Ppat_any
<BR>&nbsp;|&nbsp;Ppat_var
<B>of </B>
<B>string Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Ppat_alias
<B>of </B>
<B>pattern * string Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Ppat_constant
<B>of </B>
<B>constant</B>
<BR>&nbsp;|&nbsp;Ppat_interval
<B>of </B>
<B>constant * constant</B>
<BR>&nbsp;|&nbsp;Ppat_tuple
<B>of </B>
<B>pattern list</B>
<BR>&nbsp;|&nbsp;Ppat_construct
<B>of </B>
<B>Longident.t Asttypes.loc * pattern option</B>
<BR>&nbsp;|&nbsp;Ppat_variant
<B>of </B>
<B>Asttypes.label * pattern option</B>
<BR>&nbsp;|&nbsp;Ppat_record
<B>of </B>
<B>(Longident.t Asttypes.loc * pattern) list * Asttypes.closed_flag</B>
<BR>&nbsp;|&nbsp;Ppat_array
<B>of </B>
<B>pattern list</B>
<BR>&nbsp;|&nbsp;Ppat_or
<B>of </B>
<B>pattern * pattern</B>
<BR>&nbsp;|&nbsp;Ppat_constraint
<B>of </B>
<B>pattern * core_type</B>
<BR>&nbsp;|&nbsp;Ppat_type
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Ppat_lazy
<B>of </B>
<B>pattern</B>
<BR>&nbsp;|&nbsp;Ppat_unpack
<B>of </B>
<B>string Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Ppat_exception
<B>of </B>
<B>pattern</B>
<BR>&nbsp;|&nbsp;Ppat_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;|&nbsp;Ppat_open
<B>of </B>
<B>Longident.t Asttypes.loc * pattern</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type expression </I>
= {
<BR>&nbsp;pexp_desc&nbsp;:&nbsp;
<B>expression_desc</B>
;
<BR>&nbsp;pexp_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pexp_loc_stack&nbsp;:&nbsp;
<B>Location.t list</B>
;
<BR>&nbsp;pexp_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type expression_desc </I>
=
<BR>&nbsp;|&nbsp;Pexp_ident
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pexp_constant
<B>of </B>
<B>constant</B>
<BR>&nbsp;|&nbsp;Pexp_let
<B>of </B>
<B>Asttypes.rec_flag * value_binding list * expression</B>
<BR>&nbsp;|&nbsp;Pexp_function
<B>of </B>
<B>case list</B>
<BR>&nbsp;|&nbsp;Pexp_fun
<B>of </B>
<B>Asttypes.arg_label * expression option * pattern</B>
<B>* expression</B>
<BR>&nbsp;|&nbsp;Pexp_apply
<B>of </B>
<B>expression * (Asttypes.arg_label * expression) list</B>
<BR>&nbsp;|&nbsp;Pexp_match
<B>of </B>
<B>expression * case list</B>
<BR>&nbsp;|&nbsp;Pexp_try
<B>of </B>
<B>expression * case list</B>
<BR>&nbsp;|&nbsp;Pexp_tuple
<B>of </B>
<B>expression list</B>
<BR>&nbsp;|&nbsp;Pexp_construct
<B>of </B>
<B>Longident.t Asttypes.loc * expression option</B>
<BR>&nbsp;|&nbsp;Pexp_variant
<B>of </B>
<B>Asttypes.label * expression option</B>
<BR>&nbsp;|&nbsp;Pexp_record
<B>of </B>
<B>(Longident.t Asttypes.loc * expression) list</B>
<B>* expression option</B>
<BR>&nbsp;|&nbsp;Pexp_field
<B>of </B>
<B>expression * Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pexp_setfield
<B>of </B>
<B>expression * Longident.t Asttypes.loc * expression</B>
<BR>&nbsp;|&nbsp;Pexp_array
<B>of </B>
<B>expression list</B>
<BR>&nbsp;|&nbsp;Pexp_ifthenelse
<B>of </B>
<B>expression * expression * expression option</B>
<BR>&nbsp;|&nbsp;Pexp_sequence
<B>of </B>
<B>expression * expression</B>
<BR>&nbsp;|&nbsp;Pexp_while
<B>of </B>
<B>expression * expression</B>
<BR>&nbsp;|&nbsp;Pexp_for
<B>of </B>
<B>pattern * expression * expression</B>
<B>* Asttypes.direction_flag * expression</B>
<BR>&nbsp;|&nbsp;Pexp_constraint
<B>of </B>
<B>expression * core_type</B>
<BR>&nbsp;|&nbsp;Pexp_coerce
<B>of </B>
<B>expression * core_type option * core_type</B>
<BR>&nbsp;|&nbsp;Pexp_send
<B>of </B>
<B>expression * Asttypes.label Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pexp_new
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pexp_setinstvar
<B>of </B>
<B>Asttypes.label Asttypes.loc * expression</B>
<BR>&nbsp;|&nbsp;Pexp_override
<B>of </B>
<B>(Asttypes.label Asttypes.loc * expression) list</B>
<BR>&nbsp;|&nbsp;Pexp_letmodule
<B>of </B>
<B>string Asttypes.loc * module_expr * expression</B>
<BR>&nbsp;|&nbsp;Pexp_letexception
<B>of </B>
<B>extension_constructor * expression</B>
<BR>&nbsp;|&nbsp;Pexp_assert
<B>of </B>
<B>expression</B>
<BR>&nbsp;|&nbsp;Pexp_lazy
<B>of </B>
<B>expression</B>
<BR>&nbsp;|&nbsp;Pexp_poly
<B>of </B>
<B>expression * core_type option</B>
<BR>&nbsp;|&nbsp;Pexp_object
<B>of </B>
<B>class_structure</B>
<BR>&nbsp;|&nbsp;Pexp_newtype
<B>of </B>
<B>string Asttypes.loc * expression</B>
<BR>&nbsp;|&nbsp;Pexp_pack
<B>of </B>
<B>module_expr</B>
<BR>&nbsp;|&nbsp;Pexp_open
<B>of </B>
<B>open_declaration * expression</B>
<BR>&nbsp;|&nbsp;Pexp_letop
<B>of </B>
<B>letop</B>
<BR>&nbsp;|&nbsp;Pexp_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;|&nbsp;Pexp_unreachable
<BR>&nbsp;
<P>
<P>
<P>
<I>type case </I>
= {
<BR>&nbsp;pc_lhs&nbsp;:&nbsp;
<B>pattern</B>
;
<BR>&nbsp;pc_guard&nbsp;:&nbsp;
<B>expression option</B>
;
<BR>&nbsp;pc_rhs&nbsp;:&nbsp;
<B>expression</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type letop </I>
= {
<BR>&nbsp;let_&nbsp;:&nbsp;
<B>binding_op</B>
;
<BR>&nbsp;ands&nbsp;:&nbsp;
<B>binding_op list</B>
;
<BR>&nbsp;body&nbsp;:&nbsp;
<B>expression</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type binding_op </I>
= {
<BR>&nbsp;pbop_op&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pbop_pat&nbsp;:&nbsp;
<B>pattern</B>
;
<BR>&nbsp;pbop_exp&nbsp;:&nbsp;
<B>expression</B>
;
<BR>&nbsp;pbop_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type value_description </I>
= {
<BR>&nbsp;pval_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pval_type&nbsp;:&nbsp;
<B>core_type</B>
;
<BR>&nbsp;pval_prim&nbsp;:&nbsp;
<B>string list</B>
;
<BR>&nbsp;pval_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;pval_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type type_declaration </I>
= {
<BR>&nbsp;ptype_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;ptype_params&nbsp;:&nbsp;
<B>(core_type * Asttypes.variance) list</B>
;
<BR>&nbsp;ptype_cstrs&nbsp;:&nbsp;
<B>(core_type * core_type * Location.t) list</B>
;
<BR>&nbsp;ptype_kind&nbsp;:&nbsp;
<B>type_kind</B>
;
<BR>&nbsp;ptype_private&nbsp;:&nbsp;
<B>Asttypes.private_flag</B>
;
<BR>&nbsp;ptype_manifest&nbsp;:&nbsp;
<B>core_type option</B>
;
<BR>&nbsp;ptype_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;ptype_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type type_kind </I>
=
<BR>&nbsp;|&nbsp;Ptype_abstract
<BR>&nbsp;|&nbsp;Ptype_variant
<B>of </B>
<B>constructor_declaration list</B>
<BR>&nbsp;|&nbsp;Ptype_record
<B>of </B>
<B>label_declaration list</B>
<BR>&nbsp;|&nbsp;Ptype_open
<BR>&nbsp;
<P>
<P>
<P>
<I>type label_declaration </I>
= {
<BR>&nbsp;pld_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pld_mutable&nbsp;:&nbsp;
<B>Asttypes.mutable_flag</B>
;
<BR>&nbsp;pld_type&nbsp;:&nbsp;
<B>core_type</B>
;
<BR>&nbsp;pld_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pld_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type constructor_declaration </I>
= {
<BR>&nbsp;pcd_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pcd_args&nbsp;:&nbsp;
<B>constructor_arguments</B>
;
<BR>&nbsp;pcd_res&nbsp;:&nbsp;
<B>core_type option</B>
;
<BR>&nbsp;pcd_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pcd_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type constructor_arguments </I>
=
<BR>&nbsp;|&nbsp;Pcstr_tuple
<B>of </B>
<B>core_type list</B>
<BR>&nbsp;|&nbsp;Pcstr_record
<B>of </B>
<B>label_declaration list</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type type_extension </I>
= {
<BR>&nbsp;ptyext_path&nbsp;:&nbsp;
<B>Longident.t Asttypes.loc</B>
;
<BR>&nbsp;ptyext_params&nbsp;:&nbsp;
<B>(core_type * Asttypes.variance) list</B>
;
<BR>&nbsp;ptyext_constructors&nbsp;:&nbsp;
<B>extension_constructor list</B>
;
<BR>&nbsp;ptyext_private&nbsp;:&nbsp;
<B>Asttypes.private_flag</B>
;
<BR>&nbsp;ptyext_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;ptyext_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type extension_constructor </I>
= {
<BR>&nbsp;pext_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pext_kind&nbsp;:&nbsp;
<B>extension_constructor_kind</B>
;
<BR>&nbsp;pext_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pext_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type type_exception </I>
= {
<BR>&nbsp;ptyexn_constructor&nbsp;:&nbsp;
<B>extension_constructor</B>
;
<BR>&nbsp;ptyexn_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;ptyexn_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type extension_constructor_kind </I>
=
<BR>&nbsp;|&nbsp;Pext_decl
<B>of </B>
<B>constructor_arguments * core_type option</B>
<BR>&nbsp;|&nbsp;Pext_rebind
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;
<P>
<P>
<P>
<P>
<P>
<A NAME="lbAG">&nbsp;</A>
<H3>Class language</H3>
<P>
<P>
<I>type class_type </I>
= {
<BR>&nbsp;pcty_desc&nbsp;:&nbsp;
<B>class_type_desc</B>
;
<BR>&nbsp;pcty_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pcty_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_type_desc </I>
=
<BR>&nbsp;|&nbsp;Pcty_constr
<B>of </B>
<B>Longident.t Asttypes.loc * core_type list</B>
<BR>&nbsp;|&nbsp;Pcty_signature
<B>of </B>
<B>class_signature</B>
<BR>&nbsp;|&nbsp;Pcty_arrow
<B>of </B>
<B>Asttypes.arg_label * core_type * class_type</B>
<BR>&nbsp;|&nbsp;Pcty_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;|&nbsp;Pcty_open
<B>of </B>
<B>open_description * class_type</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type class_signature </I>
= {
<BR>&nbsp;pcsig_self&nbsp;:&nbsp;
<B>core_type</B>
;
<BR>&nbsp;pcsig_fields&nbsp;:&nbsp;
<B>class_type_field list</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_type_field </I>
= {
<BR>&nbsp;pctf_desc&nbsp;:&nbsp;
<B>class_type_field_desc</B>
;
<BR>&nbsp;pctf_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pctf_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_type_field_desc </I>
=
<BR>&nbsp;|&nbsp;Pctf_inherit
<B>of </B>
<B>class_type</B>
<BR>&nbsp;|&nbsp;Pctf_val
<B>of </B>
<B>(Asttypes.label Asttypes.loc * Asttypes.mutable_flag *</B>
<B>Asttypes.virtual_flag * core_type)</B>
<BR>&nbsp;|&nbsp;Pctf_method
<B>of </B>
<B>(Asttypes.label Asttypes.loc * Asttypes.private_flag *</B>
<B>Asttypes.virtual_flag * core_type)</B>
<BR>&nbsp;|&nbsp;Pctf_constraint
<B>of </B>
<B>(core_type * core_type)</B>
<BR>&nbsp;|&nbsp;Pctf_attribute
<B>of </B>
<B>attribute</B>
<BR>&nbsp;|&nbsp;Pctf_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type </I>
<B>'a</B>
<I>class_infos </I>
= {
<BR>&nbsp;pci_virt&nbsp;:&nbsp;
<B>Asttypes.virtual_flag</B>
;
<BR>&nbsp;pci_params&nbsp;:&nbsp;
<B>(core_type * Asttypes.variance) list</B>
;
<BR>&nbsp;pci_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pci_expr&nbsp;:&nbsp;
<B>'a</B>
;
<BR>&nbsp;pci_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pci_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_description </I>
=
<B>class_type class_infos</B>
<P>
<P>
<P>
<P>
<I>type class_type_declaration </I>
=
<B>class_type class_infos</B>
<P>
<P>
<P>
<P>
<I>type class_expr </I>
= {
<BR>&nbsp;pcl_desc&nbsp;:&nbsp;
<B>class_expr_desc</B>
;
<BR>&nbsp;pcl_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pcl_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_expr_desc </I>
=
<BR>&nbsp;|&nbsp;Pcl_constr
<B>of </B>
<B>Longident.t Asttypes.loc * core_type list</B>
<BR>&nbsp;|&nbsp;Pcl_structure
<B>of </B>
<B>class_structure</B>
<BR>&nbsp;|&nbsp;Pcl_fun
<B>of </B>
<B>Asttypes.arg_label * expression option * pattern</B>
<B>* class_expr</B>
<BR>&nbsp;|&nbsp;Pcl_apply
<B>of </B>
<B>class_expr * (Asttypes.arg_label * expression) list</B>
<BR>&nbsp;|&nbsp;Pcl_let
<B>of </B>
<B>Asttypes.rec_flag * value_binding list * class_expr</B>
<BR>&nbsp;|&nbsp;Pcl_constraint
<B>of </B>
<B>class_expr * class_type</B>
<BR>&nbsp;|&nbsp;Pcl_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;|&nbsp;Pcl_open
<B>of </B>
<B>open_description * class_expr</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type class_structure </I>
= {
<BR>&nbsp;pcstr_self&nbsp;:&nbsp;
<B>pattern</B>
;
<BR>&nbsp;pcstr_fields&nbsp;:&nbsp;
<B>class_field list</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_field </I>
= {
<BR>&nbsp;pcf_desc&nbsp;:&nbsp;
<B>class_field_desc</B>
;
<BR>&nbsp;pcf_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pcf_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type class_field_desc </I>
=
<BR>&nbsp;|&nbsp;Pcf_inherit
<B>of </B>
<B>Asttypes.override_flag * class_expr * string Asttypes.loc option</B>
<BR>&nbsp;|&nbsp;Pcf_val
<B>of </B>
<B>(Asttypes.label Asttypes.loc * Asttypes.mutable_flag *</B>
<B>class_field_kind)</B>
<BR>&nbsp;|&nbsp;Pcf_method
<B>of </B>
<B>(Asttypes.label Asttypes.loc * Asttypes.private_flag *</B>
<B>class_field_kind)</B>
<BR>&nbsp;|&nbsp;Pcf_constraint
<B>of </B>
<B>(core_type * core_type)</B>
<BR>&nbsp;|&nbsp;Pcf_initializer
<B>of </B>
<B>expression</B>
<BR>&nbsp;|&nbsp;Pcf_attribute
<B>of </B>
<B>attribute</B>
<BR>&nbsp;|&nbsp;Pcf_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type class_field_kind </I>
=
<BR>&nbsp;|&nbsp;Cfk_virtual
<B>of </B>
<B>core_type</B>
<BR>&nbsp;|&nbsp;Cfk_concrete
<B>of </B>
<B>Asttypes.override_flag * expression</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type class_declaration </I>
=
<B>class_expr class_infos</B>
<P>
<P>
<P>
<P>
<P>
<P>
<A NAME="lbAH">&nbsp;</A>
<H3>Module language</H3>
<P>
<P>
<I>type module_type </I>
= {
<BR>&nbsp;pmty_desc&nbsp;:&nbsp;
<B>module_type_desc</B>
;
<BR>&nbsp;pmty_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pmty_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type module_type_desc </I>
=
<BR>&nbsp;|&nbsp;Pmty_ident
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pmty_signature
<B>of </B>
<B>signature</B>
<BR>&nbsp;|&nbsp;Pmty_functor
<B>of </B>
<B>string Asttypes.loc * module_type option * module_type</B>
<BR>&nbsp;|&nbsp;Pmty_with
<B>of </B>
<B>module_type * with_constraint list</B>
<BR>&nbsp;|&nbsp;Pmty_typeof
<B>of </B>
<B>module_expr</B>
<BR>&nbsp;|&nbsp;Pmty_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;|&nbsp;Pmty_alias
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type signature </I>
=
<B>signature_item list</B>
<P>
<P>
<P>
<P>
<I>type signature_item </I>
= {
<BR>&nbsp;psig_desc&nbsp;:&nbsp;
<B>signature_item_desc</B>
;
<BR>&nbsp;psig_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type signature_item_desc </I>
=
<BR>&nbsp;|&nbsp;Psig_value
<B>of </B>
<B>value_description</B>
<BR>&nbsp;|&nbsp;Psig_type
<B>of </B>
<B>Asttypes.rec_flag * type_declaration list</B>
<BR>&nbsp;|&nbsp;Psig_typesubst
<B>of </B>
<B>type_declaration list</B>
<BR>&nbsp;|&nbsp;Psig_typext
<B>of </B>
<B>type_extension</B>
<BR>&nbsp;|&nbsp;Psig_exception
<B>of </B>
<B>type_exception</B>
<BR>&nbsp;|&nbsp;Psig_module
<B>of </B>
<B>module_declaration</B>
<BR>&nbsp;|&nbsp;Psig_modsubst
<B>of </B>
<B>module_substitution</B>
<BR>&nbsp;|&nbsp;Psig_recmodule
<B>of </B>
<B>module_declaration list</B>
<BR>&nbsp;|&nbsp;Psig_modtype
<B>of </B>
<B>module_type_declaration</B>
<BR>&nbsp;|&nbsp;Psig_open
<B>of </B>
<B>open_description</B>
<BR>&nbsp;|&nbsp;Psig_include
<B>of </B>
<B>include_description</B>
<BR>&nbsp;|&nbsp;Psig_class
<B>of </B>
<B>class_description list</B>
<BR>&nbsp;|&nbsp;Psig_class_type
<B>of </B>
<B>class_type_declaration list</B>
<BR>&nbsp;|&nbsp;Psig_attribute
<B>of </B>
<B>attribute</B>
<BR>&nbsp;|&nbsp;Psig_extension
<B>of </B>
<B>extension * attributes</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type module_declaration </I>
= {
<BR>&nbsp;pmd_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pmd_type&nbsp;:&nbsp;
<B>module_type</B>
;
<BR>&nbsp;pmd_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;pmd_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type module_substitution </I>
= {
<BR>&nbsp;pms_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pms_manifest&nbsp;:&nbsp;
<B>Longident.t Asttypes.loc</B>
;
<BR>&nbsp;pms_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;pms_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type module_type_declaration </I>
= {
<BR>&nbsp;pmtd_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pmtd_type&nbsp;:&nbsp;
<B>module_type option</B>
;
<BR>&nbsp;pmtd_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;pmtd_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type </I>
<B>'a</B>
<I>open_infos </I>
= {
<BR>&nbsp;popen_expr&nbsp;:&nbsp;
<B>'a</B>
;
<BR>&nbsp;popen_override&nbsp;:&nbsp;
<B>Asttypes.override_flag</B>
;
<BR>&nbsp;popen_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;popen_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type open_description </I>
=
<B>Longident.t Asttypes.loc open_infos</B>
<P>
<P>
<P>
<P>
<I>type open_declaration </I>
=
<B>module_expr open_infos</B>
<P>
<P>
<P>
<P>
<I>type </I>
<B>'a</B>
<I>include_infos </I>
= {
<BR>&nbsp;pincl_mod&nbsp;:&nbsp;
<B>'a</B>
;
<BR>&nbsp;pincl_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pincl_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type include_description </I>
=
<B>module_type include_infos</B>
<P>
<P>
<P>
<P>
<I>type include_declaration </I>
=
<B>module_expr include_infos</B>
<P>
<P>
<P>
<P>
<I>type with_constraint </I>
=
<BR>&nbsp;|&nbsp;Pwith_type
<B>of </B>
<B>Longident.t Asttypes.loc * type_declaration</B>
<BR>&nbsp;|&nbsp;Pwith_module
<B>of </B>
<B>Longident.t Asttypes.loc * Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pwith_typesubst
<B>of </B>
<B>Longident.t Asttypes.loc * type_declaration</B>
<BR>&nbsp;|&nbsp;Pwith_modsubst
<B>of </B>
<B>Longident.t Asttypes.loc * Longident.t Asttypes.loc</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type module_expr </I>
= {
<BR>&nbsp;pmod_desc&nbsp;:&nbsp;
<B>module_expr_desc</B>
;
<BR>&nbsp;pmod_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;pmod_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type module_expr_desc </I>
=
<BR>&nbsp;|&nbsp;Pmod_ident
<B>of </B>
<B>Longident.t Asttypes.loc</B>
<BR>&nbsp;|&nbsp;Pmod_structure
<B>of </B>
<B>structure</B>
<BR>&nbsp;|&nbsp;Pmod_functor
<B>of </B>
<B>string Asttypes.loc * module_type option * module_expr</B>
<BR>&nbsp;|&nbsp;Pmod_apply
<B>of </B>
<B>module_expr * module_expr</B>
<BR>&nbsp;|&nbsp;Pmod_constraint
<B>of </B>
<B>module_expr * module_type</B>
<BR>&nbsp;|&nbsp;Pmod_unpack
<B>of </B>
<B>expression</B>
<BR>&nbsp;|&nbsp;Pmod_extension
<B>of </B>
<B>extension</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type structure </I>
=
<B>structure_item list</B>
<P>
<P>
<P>
<P>
<I>type structure_item </I>
= {
<BR>&nbsp;pstr_desc&nbsp;:&nbsp;
<B>structure_item_desc</B>
;
<BR>&nbsp;pstr_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type structure_item_desc </I>
=
<BR>&nbsp;|&nbsp;Pstr_eval
<B>of </B>
<B>expression * attributes</B>
<BR>&nbsp;|&nbsp;Pstr_value
<B>of </B>
<B>Asttypes.rec_flag * value_binding list</B>
<BR>&nbsp;|&nbsp;Pstr_primitive
<B>of </B>
<B>value_description</B>
<BR>&nbsp;|&nbsp;Pstr_type
<B>of </B>
<B>Asttypes.rec_flag * type_declaration list</B>
<BR>&nbsp;|&nbsp;Pstr_typext
<B>of </B>
<B>type_extension</B>
<BR>&nbsp;|&nbsp;Pstr_exception
<B>of </B>
<B>type_exception</B>
<BR>&nbsp;|&nbsp;Pstr_module
<B>of </B>
<B>module_binding</B>
<BR>&nbsp;|&nbsp;Pstr_recmodule
<B>of </B>
<B>module_binding list</B>
<BR>&nbsp;|&nbsp;Pstr_modtype
<B>of </B>
<B>module_type_declaration</B>
<BR>&nbsp;|&nbsp;Pstr_open
<B>of </B>
<B>open_declaration</B>
<BR>&nbsp;|&nbsp;Pstr_class
<B>of </B>
<B>class_declaration list</B>
<BR>&nbsp;|&nbsp;Pstr_class_type
<B>of </B>
<B>class_type_declaration list</B>
<BR>&nbsp;|&nbsp;Pstr_include
<B>of </B>
<B>include_declaration</B>
<BR>&nbsp;|&nbsp;Pstr_attribute
<B>of </B>
<B>attribute</B>
<BR>&nbsp;|&nbsp;Pstr_extension
<B>of </B>
<B>extension * attributes</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type value_binding </I>
= {
<BR>&nbsp;pvb_pat&nbsp;:&nbsp;
<B>pattern</B>
;
<BR>&nbsp;pvb_expr&nbsp;:&nbsp;
<B>expression</B>
;
<BR>&nbsp;pvb_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;pvb_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type module_binding </I>
= {
<BR>&nbsp;pmb_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pmb_expr&nbsp;:&nbsp;
<B>module_expr</B>
;
<BR>&nbsp;pmb_attributes&nbsp;:&nbsp;
<B>attributes</B>
;
<BR>&nbsp;pmb_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<P>
<P>
<A NAME="lbAI">&nbsp;</A>
<H3>Toplevel</H3>
<P>
<P>
<I>type toplevel_phrase </I>
=
<BR>&nbsp;|&nbsp;Ptop_def
<B>of </B>
<B>structure</B>
<BR>&nbsp;|&nbsp;Ptop_dir
<B>of </B>
<B>toplevel_directive</B>
<BR>&nbsp;
<P>
<P>
<P>
<I>type toplevel_directive </I>
= {
<BR>&nbsp;pdir_name&nbsp;:&nbsp;
<B>string Asttypes.loc</B>
;
<BR>&nbsp;pdir_arg&nbsp;:&nbsp;
<B>directive_argument option</B>
;
<BR>&nbsp;pdir_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type directive_argument </I>
= {
<BR>&nbsp;pdira_desc&nbsp;:&nbsp;
<B>directive_argument_desc</B>
;
<BR>&nbsp;pdira_loc&nbsp;:&nbsp;
<B>Location.t</B>
;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<I>type directive_argument_desc </I>
=
<BR>&nbsp;|&nbsp;Pdir_string
<B>of </B>
<B>string</B>
<BR>&nbsp;|&nbsp;Pdir_int
<B>of </B>
<B>string * char option</B>
<BR>&nbsp;|&nbsp;Pdir_ident
<B>of </B>
<B>Longident.t</B>
<BR>&nbsp;|&nbsp;Pdir_bool
<B>of </B>
<B>bool</B>
<BR>&nbsp;
<P>
<P>
<P>
<P>
<HR>
<A NAME="index">&nbsp;</A><H2>Index</H2>
<DL>
<DT id="1"><A HREF="#lbAB">NAME</A><DD>
<DT id="2"><A HREF="#lbAC">Module</A><DD>
<DT id="3"><A HREF="#lbAD">Documentation</A><DD>
<DL>
<DT id="4"><A HREF="#lbAE">Extension points</A><DD>
<DT id="5"><A HREF="#lbAF">Core language</A><DD>
<DT id="6"><A HREF="#lbAG">Class language</A><DD>
<DT id="7"><A HREF="#lbAH">Module language</A><DD>
<DT id="8"><A HREF="#lbAI">Toplevel</A><DD>
</DL>
</DL>
<HR>
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 00:05:49 GMT, March 31, 2021
</BODY>
</HTML>