#[repr(C)]pub struct ArrowFunction {
pub attribute_lists: Sequence<AttributeList>,
pub static: Option<Keyword>,
pub fn: Keyword,
pub ampersand: Option<Span>,
pub parameter_list: FunctionLikeParameterList,
pub return_type_hint: Option<FunctionLikeReturnTypeHint>,
pub arrow: Span,
pub expression: Box<Expression>,
}Expand description
Represents an arrow function in PHP.
Example:
<?php
$fn = fn($x) => $x * 2;Fields§
§attribute_lists: Sequence<AttributeList>§static: Option<Keyword>§fn: Keyword§ampersand: Option<Span>§parameter_list: FunctionLikeParameterList§return_type_hint: Option<FunctionLikeReturnTypeHint>§arrow: Span§expression: Box<Expression>Trait Implementations§
Source§impl Clone for ArrowFunction
impl Clone for ArrowFunction
Source§fn clone(&self) -> ArrowFunction
fn clone(&self) -> ArrowFunction
Returns a duplicate 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 ArrowFunction
impl Debug for ArrowFunction
Source§impl<'de> Deserialize<'de> for ArrowFunction
impl<'de> Deserialize<'de> for ArrowFunction
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 HasSpan for ArrowFunction
impl HasSpan for ArrowFunction
Source§impl Hash for ArrowFunction
impl Hash for ArrowFunction
Source§impl Ord for ArrowFunction
impl Ord for ArrowFunction
Source§fn cmp(&self, other: &ArrowFunction) -> Ordering
fn cmp(&self, other: &ArrowFunction) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for ArrowFunction
impl PartialEq for ArrowFunction
Source§impl PartialOrd for ArrowFunction
impl PartialOrd for ArrowFunction
Source§impl Serialize for ArrowFunction
impl Serialize for ArrowFunction
impl Eq for ArrowFunction
impl StructuralPartialEq for ArrowFunction
Auto Trait Implementations§
impl Freeze for ArrowFunction
impl RefUnwindSafe for ArrowFunction
impl Send for ArrowFunction
impl Sync for ArrowFunction
impl Unpin for ArrowFunction
impl UnwindSafe for ArrowFunction
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