Trait hugr_core::std_extensions::ptr::PtrOpBuilder

source ·
pub trait PtrOpBuilder: Dataflow {
    // Provided methods
    fn add_new_ptr(&mut self, val_wire: Wire) -> Result<Wire, BuildError> { ... }
    fn add_read_ptr(
        &mut self,
        ptr_wire: Wire,
        ty: Type,
    ) -> Result<Wire, BuildError> { ... }
    fn add_write_ptr(
        &mut self,
        ptr_wire: Wire,
        val_wire: Wire,
    ) -> Result<(), BuildError> { ... }
}
Expand description

An extension trait for Dataflow providing methods to add pointer operations.

Provided Methods§

source

fn add_new_ptr(&mut self, val_wire: Wire) -> Result<Wire, BuildError>

Add a “ptr.New” op.

source

fn add_read_ptr(&mut self, ptr_wire: Wire, ty: Type) -> Result<Wire, BuildError>

Add a “ptr.Read” op.

source

fn add_write_ptr( &mut self, ptr_wire: Wire, val_wire: Wire, ) -> Result<(), BuildError>

Add a “ptr.Write” op.

Object Safety§

This trait is not object safe.

Implementors§