Skip to main content

OperationPtrExt

Trait OperationPtrExt 

Source
pub trait OperationPtrExt: Sized {
Show 20 methods // Required methods fn cast<T: ?Sized + OpInterfaceMarker + 'static>( self, ctx: &Context, ) -> Option<TraitOp<T>>; fn as_op<T: Op>(self, ctx: &Context) -> Option<T>; fn dyn_op(self, ctx: &Context) -> OpObj; fn operand(self, ctx: &Context, idx: usize) -> Value; fn operand_as_use(self, ctx: &Context, idx: usize) -> Use<Value>; fn operands(self, ctx: &Context) -> Vec<Value>; fn operands_as_uses(self, ctx: &Context) -> Vec<Use<Value>>; fn result(self, ctx: &Context) -> Value; fn results(self, ctx: &Context) -> Vec<Value>; fn result_types(self, ctx: &Context) -> Vec<TypeHandle>; fn regions(self, ctx: &Context) -> Vec<Ptr<Region>>; fn result_names(self, ctx: &Context) -> Vec<Option<Identifier>>; fn opt_result(self, ctx: &Context) -> Option<Value>; fn get_attr<'a, T: Attribute>( self, ctx: &'a Context, key: &Identifier, ) -> Option<Ref<'a, T>>; fn set_attr<T: Attribute>(self, ctx: &Context, key: &Identifier, value: T); fn parent_module(self, ctx: &Context) -> ModuleOp; fn is_ancestor_of(self, ctx: &Context, other: Ptr<Operation>) -> bool; // Provided methods fn is_op<T: Op>(self, ctx: &Context) -> bool { ... } fn is_terminator(self, ctx: &Context) -> bool { ... } fn impls<T: ?Sized + OpInterfaceMarker + 'static>( self, ctx: &Context, ) -> bool { ... }
}

Required Methods§

Source

fn cast<T: ?Sized + OpInterfaceMarker + 'static>( self, ctx: &Context, ) -> Option<TraitOp<T>>

Source

fn as_op<T: Op>(self, ctx: &Context) -> Option<T>

Source

fn dyn_op(self, ctx: &Context) -> OpObj

Source

fn operand(self, ctx: &Context, idx: usize) -> Value

Source

fn operand_as_use(self, ctx: &Context, idx: usize) -> Use<Value>

Source

fn operands(self, ctx: &Context) -> Vec<Value>

Source

fn operands_as_uses(self, ctx: &Context) -> Vec<Use<Value>>

Source

fn result(self, ctx: &Context) -> Value

Source

fn results(self, ctx: &Context) -> Vec<Value>

Source

fn result_types(self, ctx: &Context) -> Vec<TypeHandle>

Source

fn regions(self, ctx: &Context) -> Vec<Ptr<Region>>

Source

fn result_names(self, ctx: &Context) -> Vec<Option<Identifier>>

Source

fn opt_result(self, ctx: &Context) -> Option<Value>

Source

fn get_attr<'a, T: Attribute>( self, ctx: &'a Context, key: &Identifier, ) -> Option<Ref<'a, T>>

Source

fn set_attr<T: Attribute>(self, ctx: &Context, key: &Identifier, value: T)

Source

fn parent_module(self, ctx: &Context) -> ModuleOp

Source

fn is_ancestor_of(self, ctx: &Context, other: Ptr<Operation>) -> bool

Provided Methods§

Source

fn is_op<T: Op>(self, ctx: &Context) -> bool

Source

fn is_terminator(self, ctx: &Context) -> bool

Source

fn impls<T: ?Sized + OpInterfaceMarker + 'static>(self, ctx: &Context) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§