pub struct CaseNode {
pub node_id: NodeId,
pub labels: Vec<CaseLabel>,
pub member: Id<MemberNode>,
pub parent: Id<TypeNode>,
pub facets: Facets,
}Expand description
One case of a union, with its labels. Spec §3.3.
A case may carry several labels — case 1: case 2: long x; — so the
labels are a list, not a single value.
Fields§
§node_id: NodeIdStable identity.
labels: Vec<CaseLabel>Labels selecting this case, in declaration order.
member: Id<MemberNode>The member this case declares.
parent: Id<TypeNode>The union this case belongs to.
facets: FacetsPer-source information. Spec §4.
Trait Implementations§
impl Eq for CaseNode
impl StructuralPartialEq for CaseNode
Auto Trait Implementations§
impl Freeze for CaseNode
impl RefUnwindSafe for CaseNode
impl Send for CaseNode
impl Sync for CaseNode
impl Unpin for CaseNode
impl UnsafeUnpin for CaseNode
impl UnwindSafe for CaseNode
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