Struct valkyrie_ast::ControlNode
source · pub struct ControlNode {
pub kind: ControlKind,
pub label: LabelNode,
pub expression: Option<ExpressionKind>,
pub span: Range<u32>,
}
Expand description
always equivalent to a statement that returns ( )
, and cannot be used as an rvalue
.
Fields§
§kind: ControlKind
The type of control flow
label: LabelNode
In theory, all jumps need a destination
expression: Option<ExpressionKind>
The label of the control flow
span: Range<u32>
The range of the node
Trait Implementations§
source§impl Clone for ControlNode
impl Clone for ControlNode
source§fn clone(&self) -> ControlNode
fn clone(&self) -> ControlNode
Returns a copy 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 ControlNode
impl Debug for ControlNode
source§impl From<ControlNode> for StatementKind
impl From<ControlNode> for StatementKind
source§fn from(o: ControlNode) -> Self
fn from(o: ControlNode) -> Self
Converts to this type from the input type.
source§impl Hash for ControlNode
impl Hash for ControlNode
source§impl PartialEq for ControlNode
impl PartialEq for ControlNode
source§fn eq(&self, other: &ControlNode) -> bool
fn eq(&self, other: &ControlNode) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for ControlNode
impl StructuralPartialEq for ControlNode
Auto Trait Implementations§
impl RefUnwindSafe for ControlNode
impl Send for ControlNode
impl Sync for ControlNode
impl Unpin for ControlNode
impl UnwindSafe for ControlNode
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