package rfsm

  1. Overview
  2. Docs
A toolset for describing and simulating StateChart-like state diagrams

Install

dune-project
 Dependency

Authors

Maintainers

Sources

2.2.tar.gz
md5=ea1b496f0aa758933ae23921ee55a531
sha512=4fa72747bb2e32f91d64e4b8c24f60d6f0bdad297cc40f36d5c687ed1de900ab8441fa8a12aecf2523928833cddd5391fa87c11a1af2162ac8001467e8f485a5

doc/rfsm/Rfsm/Evseq/Make/argument-1-ES/Event/Value/index.html

Module Event.Value

type t

The type of guest-level values

type typ

The type of guest-level types

val default_value : typ -> t

default_value t should return a default value for type t

VCD interface

exception Unsupported_vcd of t
val vcd_type : t -> Vcd_types.vcd_typ

vcd_type v should return the VCD type corresponding to value v. For example, if v denotes an boolean value, vcd_type v should return Rfsm.Vcd_types.TyBool. This function should raise Unsupported_vcd in case of failure (if there's no corresponding VCD type)

val vcd_value : t -> Vcd_types.vcd_value

vcd_value v should return the VCD encoding of value v. For example, if v denotes the boolean value b, vcd_value v should return Rfsm.Vcd_types.Val_bool b. This function should raise Unsupported_vcd in case of failure (if there's no corresponding VCD value)

val flatten : base:Ident.t -> t -> (Ident.t * t) list

flatten base:b v should decompose a structured value v into a list of qualified scalar values for VCD dumping. For example, if v is a record {x=1;y=2}, then flatten ~base:"a" v should be [("a.x",1);("a.y",2)]. If v is a scalar value, then flatten ~base:"a" v is just ["a",v]

Printing

val pp : Format.formatter -> t -> unit

pp fmt v prints value v on formatter fmt.