Expand description
M5: bytecode VM. Stack machine with effect dispatch through a host handler.
Structs§
- Deny
AllEffects - A handler that fails any effect call. Useful as a default for pure-only runs.
- Null
Tracer - No-op tracer for normal execution.
- Vm
Enums§
Constants§
- MAX_
CALL_ DEPTH - Maximum simultaneous call frames. Defends against unbounded recursion in agent-emitted code: a body that calls itself without a base case would otherwise blow the host’s native stack and crash the process. Real Lex code rarely exceeds ~30 frames; 1024 is generous headroom while still well under the OS stack limit at any per-frame size we use.
Traits§
- Effect
Handler - Host-side effect dispatch. Implementors decide what
kind/opmean and how arguments map to side effects. - Tracer
- Trace receiver. Implementors record the call/effect tree and may substitute effect responses (for replay).