package tiny_languages

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

Module St_interpSource

Sourcetype host = {
  1. transcript : string -> unit;
  2. milliseconds : unit -> int;
  3. inspect : oop -> unit;
  4. mouse : unit -> int * int * int;
}
Sourcetype process_state =
  1. | Runnable
  2. | Suspended of string
  3. | Finished of oop
  4. | Terminated
Sourcetype process = {
  1. id : int;
  2. mutable top : oop;
  3. mutable state : process_state;
}
Sourcetype vm
Sourcetype primitive = vm -> int -> bool
Sourceval create : St_memory.t -> host -> vm
Sourceval memory : vm -> St_memory.t
Sourceval host : vm -> host
Sourceval set_host : vm -> host -> unit
Sourceval primitives : vm -> primitive option array
Sourceval set_extra_roots : vm -> (unit -> oop list) -> unit
Sourceval spawn : vm -> oop -> string -> oop list -> process
Sourceval spawn_method : vm -> oop -> oop -> process
Sourceval run : ?stop_when:(vm -> bool) -> vm -> process -> budget:int -> unit
Sourceval resume : process -> unit
Sourceval suspend : process -> string -> unit
Sourceval terminate : vm -> process -> unit
Sourceval call : vm -> ?budget:int -> oop -> string -> oop list -> (oop, string) result
Sourceval print_string : vm -> oop -> string
Sourceval evaluate : vm -> ?budget:int -> ?receiver:oop -> string -> (oop, string) result
Sourceval stack : vm -> int -> oop
Sourceval pop : vm -> int -> unit
Sourceval push : vm -> oop -> unit
Sourceval bool : vm -> bool -> oop
Sourceval send : vm -> oop -> int -> unit
Sourceval active_context : vm -> oop
Sourceval ip : vm -> int
Sourceval home_context : vm -> oop
Sourceval new_context : vm -> int -> temps:int -> oop
Sourceval escape : vm -> oop -> unit
Sourceval activate_context : vm -> oop -> unit
Sourceval request_suspend : vm -> string -> unit
Sourceval collect : vm -> unit
Sourceval flush_cache : vm -> unit
Sourceval cache_stats : vm -> int * int
Sourceval bytecodes_run : vm -> int
Sourceval c_sender : int
Sourceval c_ip : int
Sourceval c_sp : int
Sourceval c_method : int
Sourceval c_closure : int
Sourceval c_receiver : int
Sourceval c_home : int
Sourceval c_temps : int
Sourceval is_block_context : vm -> oop -> bool
Sourceval is_closure_context : vm -> oop -> bool
Sourceval context_method : vm -> oop -> oop
Sourceval context_home : vm -> oop -> oop