pub enum Instruction {
PAdd(isize),
DAdd(isize),
Output,
Input,
UntilZero(Vec<Instruction>),
}
Expand description
An intermediate instruction of Brainfuck-like language.
Variants§
PAdd(isize)
Unified pointer increments/decrements
DAdd(isize)
Unified data increesments/decrements
Output
Write one byte at the current pointer
Input
Read one byte and store it at the current pointer
UntilZero(Vec<Instruction>)
loop until the value at the current pointer is non-zero
Trait Implementations§
Source§impl Debug for Instruction
impl Debug for Instruction
Source§impl PartialEq for Instruction
impl PartialEq for Instruction
impl Eq for Instruction
impl StructuralPartialEq for Instruction
Auto Trait Implementations§
impl Freeze for Instruction
impl RefUnwindSafe for Instruction
impl Send for Instruction
impl Sync for Instruction
impl Unpin for Instruction
impl UnwindSafe for Instruction
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