[][src]Struct stack_vm::Frame

pub struct Frame<T> {
    pub return_address: usize,
    // some fields omitted
}

A call frame.

Contains:

  • A WriteManyTable for storage of local variables.
  • A return address - the instruction pointer for the machine to return to when returning from this call.

Fields

return_address: usize

Methods

impl<T> Frame<T>[src]

pub fn new(return_address: usize) -> Frame<T>[src]

Creates a new call frame with the specified return address.

pub fn get_local(&self, name: &str) -> Option<&T>[src]

Return a reference to the specified local variable.

pub fn set_local(&mut self, name: &str, value: T)[src]

Set the value of a local variable.

Trait Implementations

impl<T: Debug> Debug for Frame<T>[src]

Auto Trait Implementations

impl<T> Send for Frame<T> where
    T: Send

impl<T> Sync for Frame<T> where
    T: Sync

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]