Trait wasmtime_types::TypeTrace

source ·
pub trait TypeTrace {
    // Required methods
    fn trace<F, E>(&self, func: &mut F) -> Result<(), E>
       where F: FnMut(EngineOrModuleTypeIndex) -> Result<(), E>;
    fn trace_mut<F, E>(&mut self, func: &mut F) -> Result<(), E>
       where F: FnMut(&mut EngineOrModuleTypeIndex) -> Result<(), E>;
}
Expand description

A trait for things that can trace all type-to-type edges, aka all type indices within this thing.

Required Methods§

source

fn trace<F, E>(&self, func: &mut F) -> Result<(), E>

Visit each edge.

The function can break out of tracing by returning Err(E).

source

fn trace_mut<F, E>(&mut self, func: &mut F) -> Result<(), E>
where F: FnMut(&mut EngineOrModuleTypeIndex) -> Result<(), E>,

Visit each edge, mutably.

Allows updating edges.

The function can break out of tracing by returning Err(E).

Object Safety§

This trait is not object safe.

Implementors§