pub struct Func {
pub return_ty: Option<Ty>,
pub body: Box<Expr>,
pub params: Vec<FuncParam>,
pub named_params: Vec<FuncParam>,
pub generic_type_params: Vec<GenericTypeParam>,
}
Expand description
Function called with possibly missing positional arguments. May also contain environment that is needed to evaluate the body.
Fields§
§return_ty: Option<Ty>
Type requirement for the function body expression.
body: Box<Expr>
Expression containing parameter (and environment) references.
params: Vec<FuncParam>
Positional function parameters.
named_params: Vec<FuncParam>
Named function parameters.
generic_type_params: Vec<GenericTypeParam>
Generic type arguments within this function.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Func
impl<'de> Deserialize<'de> for Func
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
impl StructuralPartialEq for Func
Auto Trait Implementations§
impl Freeze for Func
impl RefUnwindSafe for Func
impl Send for Func
impl Sync for Func
impl Unpin for Func
impl UnwindSafe for Func
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