[][src]Struct bfcore::Interpreter

pub struct Interpreter<I, O> where
    I: Input,
    O: Output
{ /* fields omitted */ }

The struct containing the data for interpretting brainfuck code

Methods

impl<I, O> Interpreter<I, O> where
    I: Input,
    O: Output
[src]

pub fn new(program: &str, input: I, output: O) -> Self[src]

Create a new interpreter from a program, an input object, and an output object

pub fn run(&mut self)[src]

Execute the program. This can be done over and over again, the interpreter is reset each time. HOWEVER: State kept within your input and output objects CANNOT be reset!!! This only resets the interpreter's internal state before execution!!!!

Auto Trait Implementations

impl<I, O> Unpin for Interpreter<I, O> where
    I: Unpin,
    O: Unpin

impl<I, O> Sync for Interpreter<I, O> where
    I: Sync,
    O: Sync

impl<I, O> Send for Interpreter<I, O> where
    I: Send,
    O: Send

Blanket Implementations

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

type Error = Infallible

The type returned in the event of a conversion error.

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

impl<T> From<T> for T[src]

impl<T, U> TryInto<U> 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> Borrow<T> for T where
    T: ?Sized
[src]

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

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