Skip to content

Commit

Permalink
clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
vcfxb committed Jul 19, 2024
1 parent 6121689 commit b36e624
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion wright/src/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl Parser {
}

/// Get the next [Token] from this [Parser]. This may be a clone of a token that's already been peeked.
pub fn next(&mut self) -> Option<Token> {
pub fn next_token(&mut self) -> Option<Token> {
self.lookahead
.pop_front()
.or_else(|| self.lexer.next_token())
Expand Down
6 changes: 2 additions & 4 deletions wright/src/parser/path.rs
Original file line number Diff line number Diff line change
@@ -1,21 +1,19 @@
//! [Parse] implementation for [Path].
use super::error::ParserErrorKind;
use super::whitespace::optional_whitespace;
use super::Parser;
use super::{error::ParserError, Parse};
use crate::ast::identifier::Identifier;
use crate::ast::path::Path;
use crate::lexer::{self, Lexer};

impl Parse for Path {
fn parse(parser: &mut Parser) -> Result<Self, ParserError> {
fn parse(_parser: &mut Parser) -> Result<Self, ParserError> {
unimplemented!()
}
}

/// Parse the first (and possibly only) [Identifier] in the [Path].
fn parse_head(parser: &mut Parser) -> Result<Identifier, ParserError> {
fn _parse_head(parser: &mut Parser) -> Result<Identifier, ParserError> {
Identifier::parse(parser).map_err(|mut err| {
err.kind = ParserErrorKind::ExpectedPath;
err
Expand Down

0 comments on commit b36e624

Please sign in to comment.