Struct rant::runtime::VM

source · []
pub struct VM<'rant> { /* private fields */ }
Expand description

The Rant Virtual Machine.

Implementations

Prepares a call to a function with the specified arguments.

Checks for an active block and attempts to iterate it. If a valid element is returned, it is pushed onto the call stack.

Performs any necessary preparation (such as pushing weight intents) before pushing a block. If the block can be pushed immediately, it will be.

Consumes attributes and pushes a block onto the resolver stack.

Gets the value of an existing variable.

Defines a new variable in the current scope.

Pushes a value onto the value stack.

Removes and returns the topmost value from the value stack.

Removes and returns the topmost frame from the call stack.

Pushes a frame onto the call stack.

Pushes an empty frame onto the call stack with a single RuntimeCall intent.

Pushes a flavored frame onto the call stack.

Interrupts execution of a repeater and either continues the next iteration or exits the block.

Returns from the currently running function.

Gets a mutable reference to the topmost frame on the call stack.

Safely attempts to get a mutable reference to the topmost frame on the call stack.

Safely attempts to get a mutable reference to the frame depth frames below the top of the call stack.

Safely attempts to get a reference to the frame depth frames below the top of the call stack.

Gets a reference to the topmost frame on the call stack.

Gets a reference to the topmost RNG on the RNG stack.

Gets a copy of the topmost RNG on the RNG stack.

Adds a new RNG to the top of the RNG stack.

Removes the topmost RNG from the RNG stack and returns it.

Gets a reference to the Rant context that created the VM.

Gets a mutable reference to the Rant context that created the VM.

Gets a reference to the resolver associated with the VM.

Gets a mutable reference to the resolver associated with the VM.

Gets a reference to the program being executed by the VM.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.