package smtml

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Model Module. This module defines a symbol table that maps symbols to values. It provides utility functions for iteration, retrieval, evaluation, serialization, and parsing from various formats.

Iteration

val iter : ((Symbol.t * Value.t) -> unit) -> t -> unit

iter f tbl applies function f to all bindings in tbl.

Retrieval

val get_symbols : t -> Symbol.t list

get_symbols tbl returns the list of symbols stored in tbl.

val get_bindings : t -> (Symbol.t * Value.t) list

get_bindings tbl returns all bindings in tbl, sorted by symbol.

Evaluation

val evaluate : t -> Symbol.t -> Value.t option

evaluate tbl sym returns the value associated with symbol sym in tbl, if any.

Pretty Printing

val pp : ?no_values:bool -> t Fmt.t

pp ?no_values fmt tbl formats tbl using Fmt.t. If no_values is true, values are omitted from the output.

Serialization

val to_string : t -> string

to_string tbl converts tbl to a human-readable string.

val to_json : t -> Yojson.t

to_json tbl converts tbl to a JSON representation.

val to_json_string : t -> string

to_json_string tbl converts tbl to a JSON string.

val to_scfg : no_value:bool -> t -> Scfg.Types.config

to_scfg ~no_value tbl converts tbl to an SCFG configuration. If no_value is true, values are omitted from the output.

val to_scfg_string : no_value:bool -> t -> string

to_scfg_string ~no_value tbl converts tbl to an SCFG string.

val to_smtlib_string : t -> string

to_smtlib_string tbl converts tbl to an SMT-LIB string.

Parsing

module Parse : sig ... end
OCaml

Innovation. Community. Security.