pub struct Parser<'eng, 'tokens> {
pub tokens: Vec<Token<'tokens>>,
pub meta: Arc<SourceMeta>,
pub pos: usize,
pub diag_engine: &'eng mut DiagnosticEngine<Code>,
}Expand description
Token-stream cursor + diagnostic engine. 'tokens ties borrowed lexemes to
the source; 'eng ties the engine borrow to the caller.
Fields§
§tokens: Vec<Token<'tokens>>§meta: Arc<SourceMeta>§pos: usize§diag_engine: &'eng mut DiagnosticEngine<Code>Implementations§
Auto Trait Implementations§
impl<'eng, 'tokens> Freeze for Parser<'eng, 'tokens>
impl<'eng, 'tokens> RefUnwindSafe for Parser<'eng, 'tokens>
impl<'eng, 'tokens> Send for Parser<'eng, 'tokens>
impl<'eng, 'tokens> Sync for Parser<'eng, 'tokens>
impl<'eng, 'tokens> Unpin for Parser<'eng, 'tokens>
impl<'eng, 'tokens> UnsafeUnpin for Parser<'eng, 'tokens>
impl<'eng, 'tokens> !UnwindSafe for Parser<'eng, 'tokens>
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