package fsml

  1. Overview
  2. Docs

A valuation is a collection of (name,value) associations

type name = string
val name_to_yojson : name -> Yojson.Safe.t
type value = Expr.t
val value_to_yojson : value -> Yojson.Safe.t
type t = (name * value) list
val to_yojson : t -> Yojson.Safe.t
val compare : t -> t -> int
val to_string : t -> string
exception Invalid_valuation of t
val check : name list -> t -> unit

check names vs checks whether vs is a "complete" valuation wrt. to names. i.e. whether each variable listed in names has a valuation in vs and each variable listed in vs occurs in names. Raises Invalid_valuation in case of failure.

val empty : t
exception Duplicate of name
val add : name -> value -> t -> t
val remove : name -> t -> t
val mem : name -> t -> bool
val assoc : name -> t -> value