sway_ir::irtype

Trait TypeOption

Source
pub trait TypeOption {
    // Required method
    fn is(
        &self,
        pred: fn(_: &Type, _: &Context<'_>) -> bool,
        context: &Context<'_>,
    ) -> bool;
}
Expand description

A helper to check if an Option value is of a particular Type.

Required Methods§

Source

fn is( &self, pred: fn(_: &Type, _: &Context<'_>) -> bool, context: &Context<'_>, ) -> bool

Implementations on Foreign Types§

Source§

impl TypeOption for Option<Type>

Source§

fn is( &self, pred: fn(_: &Type, _: &Context<'_>) -> bool, context: &Context<'_>, ) -> bool

Implementors§