pub trait ConstructVisitor {
    fn from(_ctx: &Context) -> CalyxResult<Self>
        Self: Sized
fn clear_data(&mut self); fn get_opts(opts: &[&'static str], ctx: &Context) -> Vec<bool>
        Self: Named
, { ... } }
Expand description

Trait defining method that can be used to construct a Visitor from an ir::Context. This is useful when a pass needs to construct information using the context before visiting the components.

For passes that don’t need to use the context, this trait can be automatically be derived from Default.

Required methods

Construct the visitor using information from the Context

Clear the data stored in the visitor. Called before traversing the next component by ir::traversal::Visitor.

Provided methods