pub struct HaskellFunction {
pub name: String,
pub type_annotation: Option<HaskellType>,
pub equations: Vec<HaskellEquation>,
}Expand description
A Haskell function definition (possibly with multiple equations).
Example:
factorial :: Int -> Int
factorial 0 = 1
factorial n = n * factorial (n - 1)Fields§
§name: StringFunction name
type_annotation: Option<HaskellType>Type signature annotation
equations: Vec<HaskellEquation>Equations (pattern-matched clauses)
Trait Implementations§
Source§impl Clone for HaskellFunction
impl Clone for HaskellFunction
Source§fn clone(&self) -> HaskellFunction
fn clone(&self) -> HaskellFunction
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 HaskellFunction
impl Debug for HaskellFunction
Source§impl Display for HaskellFunction
impl Display for HaskellFunction
Source§impl PartialEq for HaskellFunction
impl PartialEq for HaskellFunction
impl StructuralPartialEq for HaskellFunction
Auto Trait Implementations§
impl Freeze for HaskellFunction
impl RefUnwindSafe for HaskellFunction
impl Send for HaskellFunction
impl Sync for HaskellFunction
impl Unpin for HaskellFunction
impl UnsafeUnpin for HaskellFunction
impl UnwindSafe for HaskellFunction
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