Module Fehu.Info
Step metadata dictionaries.
Info dictionaries carry auxiliary data returned by Env.reset and Step results. Keys are strings and values are Value.t.
Types
Constructors
val empty : tempty is the empty dictionary.
of_list kvs is a dictionary from the given key-value pairs.
Predicates
val is_empty : t -> boolis_empty t is true iff t has no bindings.
Operations
find_exn k t is the value bound to k in t.
Raises Invalid_argument if k is not present.
merge a b is the union of a and b. When both have a binding for the same key, the value from b wins.
Converting
to_value t is t as a Value.t.Dict.
Formatting
val pp : Stdlib.Format.formatter -> t -> unitpp formats an info dictionary for debugging.
Convenience value constructors
val null : Value.tnull is Value.t.Null.
val bool : bool -> Value.tbool b is Value.Bool b.
val int : int -> Value.tint i is Value.Int i.
val float : float -> Value.tfloat f is Value.Float f.
val string : string -> Value.tstring s is Value.String s.
val int_array : int array -> Value.tint_array arr is Value.Int_array (Array.copy arr).
val float_array : float array -> Value.tfloat_array arr is Value.Float_array (Array.copy arr).
val bool_array : bool array -> Value.tbool_array arr is Value.Bool_array (Array.copy arr).