package fieldslib
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=3d6001f7355d2dfb0f33fb7e64f39e34bda0917277609f5ec9a0703aa17b7dfa
CHANGES.md.html
113.00.00
Added
Fields.Direct.set_all_mutable_fields
, a function intended to guarantee when pooling records that one cannot forget to reinitialize some fields.Obviously one could achieve this through something like
Fields.Direct.iter
, but we want a more efficient version that doesn't force the call side to create closures.
109.19.00
Made
with fields
generate the same functions in theFields
andFields_of_*
modules whether the type is calledt
or not.
109.14.00
Made
with fields
expose first-class fields for private types while preserving privacy.There is now an additional phantom type in a first-class field that prevents building or modifying elements of a private type.
One consequence of this change is that the
Field.t
type is now an abstract type -- it used to be exposed as a record type. So, one must, e.g., changefield.Field.name
toField.name field
.
109.12.00
Added back
Fields.fold
towith fields
forprivate
types.We had removed
Fields.fold
forprivate
types, but this caused some pain. So we're putting it back. At some point, we'll patchwith fields
to prevent setting mutable fields on private types via the fields provided byfold
.
109.11.00
with fields
, for a typeu
that isn't namedt
, creates moduleFields_of_u
rather than moduleFields
. This allows one to uswith fields
on several types in the same structure.
109.10.00
Changed
with fields
onprivate
types to not expose mutators or creators.