pub struct Lexer<'a> {
pub line: usize,
pub column: usize,
pub last_line: usize,
pub last_column: usize,
pub diagnostics: Vec<PlacedError>,
pub success: bool,
/* private fields */
}
Fields
line: usize
column: usize
last_line: usize
last_column: usize
diagnostics: Vec<PlacedError>
success: bool
Implementations
sourceimpl<'a> Lexer<'a>
impl<'a> Lexer<'a>
pub fn new(input: &'a str) -> Self
pub fn read_char(&mut self)
pub fn skip_whitespace(&mut self)
pub fn read_line(&mut self) -> String
pub fn read_identifier(&mut self, first: Option<char>) -> String
pub fn read_trait_identifier(&mut self) -> String
pub fn read_principal(&mut self) -> String
pub fn read_unsigned(&mut self) -> u128
pub fn read_integer(&mut self) -> i128
pub fn read_hex(&mut self) -> Vec<u8>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
A: Allocator,
pub fn read_ascii_string(&mut self) -> String
pub fn read_utf8_encoding(&mut self) -> String
pub fn read_utf8_string(&mut self) -> Vec<Vec<u8>>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
A: Allocator,
pub fn read_token(&mut self) -> PlacedToken
Auto Trait Implementations
impl<'a> RefUnwindSafe for Lexer<'a>
impl<'a> Send for Lexer<'a>
impl<'a> Sync for Lexer<'a>
impl<'a> Unpin for Lexer<'a>
impl<'a> UnwindSafe for Lexer<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
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