#[repr(C)]pub struct MatchExpression<'gc> {
pub metadata: NodeMetadata<'gc>,
pub argument: &'gc Node<'gc>,
pub cases: NodeList<'gc>,
}Expand description
The MatchExpression AST node.
Fields§
§metadata: NodeMetadata<'gc>Source range, debug location, paren count, and node id.
argument: &'gc Node<'gc>ESTree argument property.
cases: NodeList<'gc>ESTree cases property.
Implementations§
Source§impl<'gc> MatchExpression<'gc>
impl<'gc> MatchExpression<'gc>
Sourcepub fn new(
metadata: NodeMetadata<'gc>,
argument: &'gc Node<'gc>,
cases: NodeList<'gc>,
) -> Self
pub fn new( metadata: NodeMetadata<'gc>, argument: &'gc Node<'gc>, cases: NodeList<'gc>, ) -> Self
Build MatchExpression from its metadata and ESTree.def fields.
Trait Implementations§
Auto Trait Implementations§
impl<'gc> !Freeze for MatchExpression<'gc>
impl<'gc> !RefUnwindSafe for MatchExpression<'gc>
impl<'gc> !Send for MatchExpression<'gc>
impl<'gc> !Sync for MatchExpression<'gc>
impl<'gc> !UnwindSafe for MatchExpression<'gc>
impl<'gc> Unpin for MatchExpression<'gc>
impl<'gc> UnsafeUnpin for MatchExpression<'gc>
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