Skip to main content

VariantMember

Trait VariantMember 

Source
pub trait VariantMember: Sized {
    // Required methods
    fn get_if(v: &Variant) -> Option<&Self>;
    fn get_if_mut(v: &mut Variant) -> Option<&mut Self>;
}
Expand description

get_if<T>(&v) over this variant, the Rust shape of C++ overload-on-T.

Required Methods§

Source

fn get_if(v: &Variant) -> Option<&Self>

Source

fn get_if_mut(v: &mut Variant) -> Option<&mut Self>

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§