From 141d69cb60d4f565f06ccd4ebeb353e748fadb7f Mon Sep 17 00:00:00 2001 From: Laurenz Date: Wed, 19 Aug 2020 21:12:34 +0200 Subject: =?UTF-8?q?Remove=20some=20obsolete=20stuff=20=E2=9D=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/syntax/parsing.rs | 4 ++-- src/syntax/tokens.rs | 3 --- 2 files changed, 2 insertions(+), 5 deletions(-) (limited to 'src/syntax') diff --git a/src/syntax/parsing.rs b/src/syntax/parsing.rs index 8dd567d3..65e860cf 100644 --- a/src/syntax/parsing.rs +++ b/src/syntax/parsing.rs @@ -177,7 +177,7 @@ impl Parser<'_> { self.eat(); self.skip_white(); - (Some(ident), try_opt_or!(self.parse_expr(), { + (Some(ident), try_or!(self.parse_expr(), { self.expected("value"); continue; })) @@ -191,7 +191,7 @@ impl Parser<'_> { _ => (None, ident.map(|id| Expr::Ident(id))) } } else { - (None, try_opt_or!(self.parse_expr(), { + (None, try_or!(self.parse_expr(), { self.expected("value"); continue; })) diff --git a/src/syntax/tokens.rs b/src/syntax/tokens.rs index a27ef982..50eea455 100644 --- a/src/syntax/tokens.rs +++ b/src/syntax/tokens.rs @@ -153,9 +153,6 @@ pub enum TokenMode { impl<'s> Tokens<'s> { /// Create a new token iterator with the given mode. - /// - /// The first token's span starts an the given `offset` position instead of - /// the zero position. pub fn new(src: &'s str, mode: TokenMode) -> Self { Self { src, -- cgit v1.2.3