pub struct TypeFamilyDecl {
pub doc: Option<DocComment>,
pub name: Ident,
pub params: Vec<TyVar>,
pub kind: Option<Kind>,
pub family_kind: TypeFamilyKind,
pub equations: Vec<TypeFamilyEqn>,
pub span: Span,
}Expand description
A standalone type family declaration.
Open: type family F a
Closed: type family F a where F Int = Bool; F a = ()
Fields§
§doc: Option<DocComment>Documentation comment.
name: IdentThe family name.
params: Vec<TyVar>Type parameters.
kind: Option<Kind>Optional result kind signature.
family_kind: TypeFamilyKindWhether this family is open or closed.
equations: Vec<TypeFamilyEqn>Equations (only for closed families).
span: SpanThe span.
Trait Implementations§
Source§impl Clone for TypeFamilyDecl
impl Clone for TypeFamilyDecl
Source§fn clone(&self) -> TypeFamilyDecl
fn clone(&self) -> TypeFamilyDecl
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TypeFamilyDecl
impl RefUnwindSafe for TypeFamilyDecl
impl Send for TypeFamilyDecl
impl Sync for TypeFamilyDecl
impl Unpin for TypeFamilyDecl
impl UnsafeUnpin for TypeFamilyDecl
impl UnwindSafe for TypeFamilyDecl
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