pub struct LexedSource { /* private fields */ }Expand description
Source text and its tokens. Read-only access keeps their ranges valid.
Implementations§
Source§impl LexedSource
impl LexedSource
pub fn source(&self) -> &str
Sourcepub fn into_source(self) -> String
pub fn into_source(self) -> String
Return the owned source, releasing its tokens and diagnostics.
pub fn tokens(&self) -> &[Token]
pub fn diagnostics(&self) -> &[Diagnostic]
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LexedSource
impl RefUnwindSafe for LexedSource
impl Send for LexedSource
impl Sync for LexedSource
impl Unpin for LexedSource
impl UnsafeUnpin for LexedSource
impl UnwindSafe for LexedSource
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