Trait orca_wasm::iterator::iterator_trait::Iterator

source ·
pub trait Iterator {
    // Required methods
    fn reset(&mut self);
    fn next(&mut self) -> Option<&Operator<'_>>;
    fn curr_loc(&self) -> (Location, bool);
    fn curr_op(&self) -> Option<&Operator<'_>>;
}
Expand description

Iterator trait that must be satisfied by all Iterators to enable code traversal.

Required Methods§

source

fn reset(&mut self)

Reset the Iterator and all Child Iterators and SubIterators

source

fn next(&mut self) -> Option<&Operator<'_>>

Go to the next Instruction

source

fn curr_loc(&self) -> (Location, bool)

Returns the Current Location as a Location and a bool value that says whether the location is at the end of the function.

source

fn curr_op(&self) -> Option<&Operator<'_>>

Get the current instruction

Implementors§

source§

impl<'a> Iterator for ModuleIterator<'_, 'a>

source§

impl<'a, 'b> Iterator for ComponentIterator<'a, 'b>