#[non_exhaustive]pub enum FunctionReturnStructField {
Basic(BasicType),
ClassRef(ClassDeclarationHandle),
Iterator(AbstractIteratorHandle),
Struct(UniversalOr<FunctionReturnStructField>),
}
Expand description
Types that can be used in a function return value
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Basic(BasicType)
ClassRef(ClassDeclarationHandle)
Iterator(AbstractIteratorHandle)
Struct(UniversalOr<FunctionReturnStructField>)
Trait Implementations§
source§impl Clone for FunctionReturnStructField
impl Clone for FunctionReturnStructField
source§fn clone(&self) -> FunctionReturnStructField
fn clone(&self) -> FunctionReturnStructField
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 FunctionReturnStructField
impl Debug for FunctionReturnStructField
source§impl From<BasicType> for FunctionReturnStructField
impl From<BasicType> for FunctionReturnStructField
source§impl From<Handle<AbstractIterator<Unvalidated>>> for FunctionReturnStructField
impl From<Handle<AbstractIterator<Unvalidated>>> for FunctionReturnStructField
source§fn from(x: AbstractIteratorHandle) -> Self
fn from(x: AbstractIteratorHandle) -> Self
Converts to this type from the input type.
source§impl From<Handle<ClassDeclaration>> for FunctionReturnStructField
impl From<Handle<ClassDeclaration>> for FunctionReturnStructField
source§fn from(x: ClassDeclarationHandle) -> Self
fn from(x: ClassDeclarationHandle) -> Self
Converts to this type from the input type.
source§impl From<Handle<Struct<FunctionReturnStructField, Unvalidated>>> for FunctionReturnStructField
impl From<Handle<Struct<FunctionReturnStructField, Unvalidated>>> for FunctionReturnStructField
source§fn from(x: FunctionReturnStructHandle) -> Self
fn from(x: FunctionReturnStructHandle) -> Self
Converts to this type from the input type.
source§impl From<Primitive> for FunctionReturnStructField
impl From<Primitive> for FunctionReturnStructField
source§impl InitializerValidator for FunctionReturnStructField
impl InitializerValidator for FunctionReturnStructField
source§fn validate_default_value(
&self,
value: &InitializerDefault
) -> BindResult<ValidatedDefaultValue>
fn validate_default_value( &self, value: &InitializerDefault ) -> BindResult<ValidatedDefaultValue>
Check that the value is valid for the type
fn bad_initializer_value( field_type: String, value: &InitializerDefault ) -> BindResult<ValidatedDefaultValue>
source§impl StructFieldType for FunctionReturnStructField
impl StructFieldType for FunctionReturnStructField
source§fn create_struct_type(
v: Handle<Struct<Self, Unvalidated>>
) -> StructType<Unvalidated>
fn create_struct_type( v: Handle<Struct<Self, Unvalidated>> ) -> StructType<Unvalidated>
convert a structure to a StructType
Auto Trait Implementations§
impl RefUnwindSafe for FunctionReturnStructField
impl !Send for FunctionReturnStructField
impl !Sync for FunctionReturnStructField
impl Unpin for FunctionReturnStructField
impl UnwindSafe for FunctionReturnStructField
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more