pub struct LambdaFunction {
pub args: ThinVec<ExprKind>,
pub body: ExprKind,
pub location: SyntaxObject,
pub rest: bool,
pub syntax_object_id: u32,
pub kwargs: bool,
}Fields§
§args: ThinVec<ExprKind>§body: ExprKind§location: SyntaxObject§rest: bool§syntax_object_id: u32§kwargs: boolImplementations§
Source§impl LambdaFunction
impl LambdaFunction
pub fn new( args: ThinVec<ExprKind>, body: ExprKind, location: SyntaxObject, ) -> Self
pub fn new_with_rest_arg( args: ThinVec<ExprKind>, body: ExprKind, location: SyntaxObject, ) -> Self
pub fn new_maybe_rest( args: ThinVec<ExprKind>, body: ExprKind, location: SyntaxObject, rest: bool, ) -> Self
pub fn arguments(&self) -> Option<Vec<&InternedString>>
pub fn arguments_mut(&mut self) -> impl Iterator<Item = &mut InternedString>
pub fn syntax_objects_arguments_mut( &mut self, ) -> impl Iterator<Item = &mut SyntaxObject>
Trait Implementations§
Source§impl Clone for LambdaFunction
impl Clone for LambdaFunction
Source§impl Debug for LambdaFunction
impl Debug for LambdaFunction
Source§impl<'de> Deserialize<'de> for LambdaFunction
impl<'de> Deserialize<'de> for LambdaFunction
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 Display for LambdaFunction
impl Display for LambdaFunction
Source§impl From<LambdaFunction> for ExprKind
impl From<LambdaFunction> for ExprKind
Source§fn from(val: LambdaFunction) -> Self
fn from(val: LambdaFunction) -> Self
Converts to this type from the input type.
Source§impl PartialEq for LambdaFunction
impl PartialEq for LambdaFunction
Source§impl Serialize for LambdaFunction
impl Serialize for LambdaFunction
Auto Trait Implementations§
impl Freeze for LambdaFunction
impl RefUnwindSafe for LambdaFunction
impl Send for LambdaFunction
impl Sync for LambdaFunction
impl Unpin for LambdaFunction
impl UnsafeUnpin for LambdaFunction
impl UnwindSafe for LambdaFunction
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> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
Fallible version of
ToCompactString::to_compact_string() Read moreSource§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
Converts the given value to a
CompactString. Read more