Module Imandrakit_ser.Value

Serialization representation.

A Ser_value.t describes how to serialized some structured data into bytes. It reflects the shape of the structured data but does not commit to a particular serialization format.

type t = private
  1. | Null
  2. | Bool of bool
  3. | Str of string
  4. | Bytes of string
  5. | Int of int64
  6. | Float of float
  7. | List of t list
  8. | Dict of t Imandrakit_common.Str_map.t
  9. | Tag of int * t
val equal : t -> t -> Ppx_deriving_runtime.bool

Helpers

val is_null : t -> bool
val hash : t -> int

Constructors

val null : t
val bool : bool -> t
val int : int -> t
val int64 : int64 -> t
val float : float -> t
val string : string -> t
val bytes : string -> t
val list : t list -> t
val dict_of_list : (string * t) list -> t
val tag : int -> t -> t