From 61c36c4def2416500f25d2484422c44829903915 Mon Sep 17 00:00:00 2001 From: greg Date: Sun, 3 Jan 2016 22:28:55 -0800 Subject: [PATCH] Fix assign parsing = is a keyword not an identifier --- src/parser.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/parser.rs b/src/parser.rs index 656b097..1bc5191 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -147,7 +147,7 @@ impl Parser { try!(self.expect(Keyword(Kw::Let))); let name = try!(self.expect_identifier()); match self.lookahead() { - Some(Identifier(ref s)) if s == "=" => { self.next(); }, + Some(Keyword(Kw::Assign)) => { self.next(); }, _ => return parse_error!("Expected `=`"), }