pub struct TypeNode {
pub path: Vec<String>,
pub generics: Vec<TypeNode>,
pub is_optional: bool,
pub range: TokenRange,
pub variant_fields: Option<Vec<(String, TypeNode)>>,
pub doc_comment: Option<String>,
}Fields§
§path: Vec<String>§generics: Vec<TypeNode>§is_optional: bool§range: TokenRange§variant_fields: Option<Vec<(String, TypeNode)>>Some(_) only when this node is an alternative inside the lowered
internal representation of #enum. Some(vec![]) is a unit variant;
Some(non-empty) carries the variant payload as (field_name, field_type)
pairs. Stays None for every non-variant type expression.
doc_comment: Option<String>Documentation extracted from leading comments.
Trait Implementations§
impl StructuralPartialEq for TypeNode
Auto Trait Implementations§
impl Freeze for TypeNode
impl RefUnwindSafe for TypeNode
impl Send for TypeNode
impl Sync for TypeNode
impl Unpin for TypeNode
impl UnsafeUnpin for TypeNode
impl UnwindSafe for TypeNode
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