[][src]Enum bfc_rs::BrainfuckInstr

pub enum BrainfuckInstr {
    PointerDec,
    PointerInc,
    DataDec,
    DataInc,
    GetByte,
    PutByte,
    WhileNonzero,
    EndWhile,
    PointerSub(u16),
    PointerAdd(u16),
    DataSub(u8),
    DataAdd(u8),
    Print(u16),
}

Type representing a standard or virtual Brainfuck instruction.

Variants

PointerDec

Move the data pointer back one cell.

PointerInc

Move the data pointer forward one cell.

DataDec

Decrement the value of the current memory cell.

DataInc

Increment the value of the current memory cell.

GetByte

Get a byte from the standard input and store it in the current memory cell.

PutByte

Write the current memory cell's value to the standard output.

WhileNonzero

Begin a while loop conditional on the current value not being zero.

EndWhile

Close the while loop.

PointerSub(u16)

Subtract from the pointer.

PointerAdd(u16)

Add to the pointer.

DataSub(u8)

Subtract from the current numer.

DataAdd(u8)

Add to the current number.

Print(u16)

Print a number of bytes to the standard output at once.

Trait Implementations

impl Clone for BrainfuckInstr[src]

impl Debug for BrainfuckInstr[src]

impl PartialEq<BrainfuckInstr> for BrainfuckInstr[src]

impl StructuralPartialEq for BrainfuckInstr[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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> 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.