#[non_exhaustive]pub enum Statement {
Simple {
tokens: Vec<Token>,
span: SourceSpan,
},
Block {
header: Vec<Token>,
body: Vec<Statement>,
span: SourceSpan,
},
Directive(Token),
}Expand description
Source syntax retains duplicate properties and unknown declarations in order.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Simple
A statement ending in a semicolon, such as a property or module import.
Block
A brace-delimited declaration, including nested and inline objects.
Directive(Token)
A preprocessing line, retained without executing or evaluating it.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Statement
impl RefUnwindSafe for Statement
impl Send for Statement
impl Sync for Statement
impl Unpin for Statement
impl UnsafeUnpin for Statement
impl UnwindSafe for Statement
Blanket Implementations§
impl<T> Allocation for T
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