diff --git a/src/parser/mod.rs b/src/parser/mod.rs index 609e830..7692d13 100644 --- a/src/parser/mod.rs +++ b/src/parser/mod.rs @@ -215,7 +215,7 @@ impl<'a> Parser<'a> { let body = self.parse_body()?; - Ok(Stmt::If { cond: cond, body }.into()) + Ok(Stmt::If { cond, body }.into()) } /// Parse loop diff --git a/src/parser/ops.rs b/src/parser/ops.rs index 42c01a9..bfd0053 100644 --- a/src/parser/ops.rs +++ b/src/parser/ops.rs @@ -153,10 +153,8 @@ impl<'a> Parser<'a> { self.lexer.next(); return Ok(buf); } - None => return Ok(buf.into()), - Some(t) => { - self.parse_operation(Some(t), buf)? - } + None => return Ok(buf), + Some(t) => self.parse_operation(Some(t), buf)?, }; } }