pub enum SampleUnion {
One(String),
Two(TestResult),
Three(F32Data),
Four(F64Data),
}Expand description
A test of union
Variants§
One(String)
first field is a String n(0)
Two(TestResult)
Second field is a TestResult n(1)
Three(F32Data)
Third field is array of f32 n(2)
Four(F64Data)
Fourth field is array of f64 n(3)
Trait Implementations§
source§impl Clone for SampleUnion
impl Clone for SampleUnion
source§fn clone(&self) -> SampleUnion
fn clone(&self) -> SampleUnion
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for SampleUnion
impl Debug for SampleUnion
source§impl<'de> Deserialize<'de> for SampleUnion
impl<'de> Deserialize<'de> for SampleUnion
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq<SampleUnion> for SampleUnion
impl PartialEq<SampleUnion> for SampleUnion
source§fn eq(&self, other: &SampleUnion) -> bool
fn eq(&self, other: &SampleUnion) -> bool
This method tests for
self and other values to be equal, and is used
by ==.