pub enum MachineAction {
Clear,
Run(String),
}Expand description
Actions that callables can request the Machine to perform after an upcall returns.
Because callables don’t have direct access to the Machine, they push requests onto an action queue. The Machine’s exec loop drains this queue after each upcall, performing any requested side effects before resuming execution.
Variants§
Clear
Reset all runtime state (variables, heap, clearables, last error).
Run(String)
Switches execution to the given program.
Trait Implementations§
Source§impl Clone for MachineAction
impl Clone for MachineAction
Source§fn clone(&self) -> MachineAction
fn clone(&self) -> MachineAction
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MachineAction
impl Debug for MachineAction
Source§impl PartialEq for MachineAction
impl PartialEq for MachineAction
Source§fn eq(&self, other: &MachineAction) -> bool
fn eq(&self, other: &MachineAction) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for MachineAction
impl StructuralPartialEq for MachineAction
Auto Trait Implementations§
impl Freeze for MachineAction
impl RefUnwindSafe for MachineAction
impl Send for MachineAction
impl Sync for MachineAction
impl Unpin for MachineAction
impl UnsafeUnpin for MachineAction
impl UnwindSafe for MachineAction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more