pub enum TypeHintKind {
Named(Name),
Keyword(BuiltinType, Span),
Nullable(Box<TypeHint>),
Union(Box<[TypeHint]>),
Intersection(Box<[TypeHint]>),
}Expand description
The shape of a type declaration.
Variants§
Named(Name)
A class or other user-defined type name.
Keyword(BuiltinType, Span)
Serialises as Named — see TypeHintKind::Keyword.
Nullable(Box<TypeHint>)
?T.
Union(Box<[TypeHint]>)
A|B.
Intersection(Box<[TypeHint]>)
A&B.
Trait Implementations§
Source§impl Clone for TypeHintKind
impl Clone for TypeHintKind
Source§impl Debug for TypeHintKind
impl Debug for TypeHintKind
Auto Trait Implementations§
impl Freeze for TypeHintKind
impl RefUnwindSafe for TypeHintKind
impl Send for TypeHintKind
impl Sync for TypeHintKind
impl Unpin for TypeHintKind
impl UnsafeUnpin for TypeHintKind
impl UnwindSafe for TypeHintKind
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