Struct ExprReturn

struct ExprReturn { ... }

A return, with an optional value to be returned.

Fields

attrs: Vec<Attribute>
return_token: Return
expr: Option<Box<Expr>>

Implementations

impl Clone for ExprReturn

fn clone(self: &Self) -> Self

impl Debug for ExprReturn

fn fmt(self: &Self, formatter: &mut Formatter<'_>) -> Result

impl Eq for ExprReturn

impl Freeze for ExprReturn

impl Hash for ExprReturn

fn hash<H>(self: &Self, state: &mut H)
where
    H: Hasher

impl Parse for ExprReturn

fn parse(input: ParseStream<'_>) -> Result<Self>

impl PartialEq for ExprReturn

fn eq(self: &Self, other: &Self) -> bool

impl RefUnwindSafe for ExprReturn

impl Send for ExprReturn

impl Sync for ExprReturn

impl ToTokens for ExprReturn

fn to_tokens(self: &Self, tokens: &mut TokenStream)

impl Unpin for ExprReturn

impl UnsafeUnpin for ExprReturn

impl UnwindSafe for ExprReturn

impl<T> Any for ExprReturn

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for ExprReturn

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for ExprReturn

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> CloneToUninit for ExprReturn

unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)

impl<T> From for ExprReturn

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Spanned for ExprReturn

fn span(self: &Self) -> Span

impl<T> ToOwned for ExprReturn

fn to_owned(self: &Self) -> T
fn clone_into(self: &Self, target: &mut T)

impl<T, U> Into for ExprReturn

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for ExprReturn

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for ExprReturn

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>