pub enum Token<'a> {
Field(Field<'a>),
Comment {
is_inline: bool,
inner: Cow<'a, str>,
},
}Expand description
The output struct for g-code emission implementing std::fmt::Display
Any strings here are expected to have escaped characters, see https://www.reprap.org/wiki/G-code#Quoted_strings
Variants§
Trait Implementations§
source§impl<'a, 'input: 'a> From<&'a InlineComment<'input>> for Token<'input>
impl<'a, 'input: 'a> From<&'a InlineComment<'input>> for Token<'input>
source§fn from(comment: &'a ParsedInlineComment<'input>) -> Self
fn from(comment: &'a ParsedInlineComment<'input>) -> Self
Converts to this type from the input type.
source§impl<'input> From<&Comment<'input>> for Token<'input>
impl<'input> From<&Comment<'input>> for Token<'input>
source§fn from(comment: &ParsedComment<'input>) -> Self
fn from(comment: &ParsedComment<'input>) -> Self
Converts to this type from the input type.
source§impl<'input> From<&Field<'input>> for Token<'input>
impl<'input> From<&Field<'input>> for Token<'input>
source§fn from(field: &ParsedField<'input>) -> Self
fn from(field: &ParsedField<'input>) -> Self
Converts to this type from the input type.