Enum canadensis_dsdl_parser::Statement
source · [−]pub enum Statement<'i> {
Directive {
name: Identifier<'i>,
value: Option<Expression<'i>>,
},
Constant {
ty: PrimitiveType,
name: Identifier<'i>,
value: Expression<'i>,
},
Field {
ty: Type<'i>,
name: Identifier<'i>,
span: Span<'i>,
},
PaddingField {
bits: u8,
span: Span<'i>,
},
ServiceResponseMarker(Span<'i>),
}
Expand description
A statement in a DSDL file
Variants
Directive
A directive, like @assert
Constant
A constant, like uint8 THINGY = 9
Field
A field, like uint16 value
PaddingField
A void padding field, like void6
ServiceResponseMarker(Span<'i>)
The ---
marker that separates the request and response fields in a service type
Trait Implementations
Auto Trait Implementations
impl<'i> RefUnwindSafe for Statement<'i>
impl<'i> Send for Statement<'i>
impl<'i> Sync for Statement<'i>
impl<'i> Unpin for Statement<'i>
impl<'i> UnwindSafe for Statement<'i>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more