pub struct Parser<'input, I>{ /* private fields */ }
Implementations§
Source§impl<I> Parser<'_, I>
impl<I> Parser<'_, I>
pub fn expression_with_prefix( &mut self, first_expression_part: Option<Expr>, ) -> Result<Expr, ParseError>
pub fn expression(&mut self) -> Result<Expr, ParseError>
pub fn parse_expression( &mut self, binding_power: u8, ) -> Result<Expr, ParseError>
pub fn parse_expression_with_prefix( &mut self, binding_power: u8, first_expression_part: Option<Expr>, ) -> Result<Expr, ParseError>
pub fn parse_const_literal(&mut self) -> Result<Lit, ParseError>
pub fn parse_literal(&mut self) -> Option<Lit>
Source§impl<I> Parser<'_, I>
impl<I> Parser<'_, I>
pub fn file(&mut self) -> Result<Vec<Item>, ParseError>
pub fn item(&mut self) -> Result<Item, ParseError>
Sourcepub fn block(
&mut self,
multi_line: bool,
end_tokens: &[TokenKind],
) -> Result<Vec<Stmt>, ParseError>
pub fn block( &mut self, multi_line: bool, end_tokens: &[TokenKind], ) -> Result<Vec<Stmt>, ParseError>
Parse a block of statements until we reach an end
token.
pub fn statement(&mut self, consume_delimiter: bool) -> Result<Stmt, ParseError>
pub fn type_(&mut self) -> Result<Type, ParseError>
Auto Trait Implementations§
impl<'input, I> Freeze for Parser<'input, I>where
I: Freeze,
impl<'input, I> RefUnwindSafe for Parser<'input, I>where
I: RefUnwindSafe,
impl<'input, I> Send for Parser<'input, I>where
I: Send,
impl<'input, I> Sync for Parser<'input, I>where
I: Sync,
impl<'input, I> Unpin for Parser<'input, I>where
I: Unpin,
impl<'input, I> UnwindSafe for Parser<'input, I>where
I: UnwindSafe,
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