Gist.Product
Operating on products.
type 'p t = 'p product
The type for products.
make fields
is a product with:
fields
the ordered sequence of fields of the product.meta
is the metadata (defaults to Meta.empty
).name
the name of the product (defaults to ""
). For records this is the type name. For variant cases this is the case constructor name. For products, if non empty, this is the type name of a type abbreviation.val name : 'p product -> string
val is_empty : 'p product -> bool
is_empty p
is true
if p
has no fields.
val is_singleton : 'p product -> bool
is_singleton p
is true
if p
has a single field.
val rec_field_count : 'p product -> int
rec_field_count c
is the number of recursive fields in c
.
This intermediate structure is used for constructing product descriptions.