pub struct Function {
pub attributes: Vec<Spanned<Attribute>>,
pub name: Span,
pub parameters: Vec<Spanned<FormalParameter>>,
pub return_attributes: Vec<Spanned<Attribute>>,
pub return_type: Option<TypeExpression>,
pub body: CompoundStatement,
}Fields§
§attributes: Vec<Spanned<Attribute>>§name: Span§parameters: Vec<Spanned<FormalParameter>>§return_attributes: Vec<Spanned<Attribute>>§return_type: Option<TypeExpression>§body: CompoundStatementTrait Implementations§
Source§impl SpannedSyntax for Function
impl SpannedSyntax for Function
fn with_source<'s>(&self, source: &'s str) -> WithSource<'s, &Self>
impl StructuralPartialEq for Function
Auto Trait Implementations§
impl Freeze for Function
impl RefUnwindSafe for Function
impl Send for Function
impl Sync for Function
impl Unpin for Function
impl UnwindSafe for Function
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more