Module Expr

module Expr: sig  end
Expression compilation and evalutation routines

type t
Code of an expression

type v =
| VrNumber of int
| VrString of string
| VrThing of Thing.t (*a thing in the hyrarchical data structure*)
| VrBool of bool (*boolean value*)
| VrFunction of (int * (v list -> v)) (*a function*)
| VrExtern of int (*a pre-declared function*)
| VrHtml of Html.t list (*a set of html tags*)
| VrInFile of Pervasives.in_channel (*a file handle*)
| VrOutFile of Pervasives.out_channel
| VrDir of Unix.dir_handle (*a directory*)
| VrFloat of float
| VrArray of (int, Bigarray.int_elt, Bigarray.c_layout) Bigarray.Array1.t
| VrError (*error of null state*)
Contents of a variable

val scan : string -> t
Scan the expression inside the string
val eval : t -> v
Evaluate an expression into a variable value
val string_of_var : v -> string
Convert a variable value into a string
val dump : (string -> unit) -> t -> unit
Dump with the function the byte-code of the expression
val var_new : string -> v -> unit
Create a new variable with a given contents
val var_del : string -> unit
Remove the variable
val var_get : string -> v
Get the contents of the variable
val var_init : unit -> unit
Clear the non system variables
val var_restore : unit -> unit
Restore the situation before the last init