Module type Bonsai_types.Definition
val extension_constructor : Stdlib.Obj.Extension_constructor.t
The easiest way to define
extension_constructor
is to use the built-in extension node:type ('input, 'model, 'action, 'result, 'incr, 'event) unpacked += | C : foo -> (_, _, _, _, _, _) unpacked let extension_constructor = [%extension_constructor C]
val sexp_of_unpacked : ('a, 'b, 'c, 'd, 'e, 'f) unpacked -> Core_kernel.Sexp.t
Only needs to handle the case(s) defined in this module.
val eval : ('input, 'model, 'action, 'result, 'incr, 'event) eval_type
Only needs to handle the case(s) defined in this module.
val visit : ('input, 'result, 'incr, 'event) Packed.t -> Visitor.t -> ('input, 'result, 'incr, 'event) Packed.t
An implementation of
visit
only needs to handle the cases defined in this module.The implementation of
visit
should callvisit_ext
on any subcomponents contained in the constructor. With the new subcomponents returned byvisit_ext
, the implementation should re-construct itself, and callvisit
on this new value.