From aa5000c6c8460132db254be55369ddcca744a5ef Mon Sep 17 00:00:00 2001 From: HTG-YT <39023054+HTG-YT@users.noreply.github.com> Date: Sun, 13 Jun 2021 13:24:09 +0800 Subject: [PATCH] handle `Token::Rickroll` in parser --- src/parser.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/parser.rs b/src/parser.rs index f7b7b9b1..59f10120 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -78,6 +78,10 @@ impl<'source> Parser<'source> { self.semi_terminated(StmtKind::Rlyeh)?, start..self.lexer.span().end, )), + Token::Rickroll => Ok(Stmt::new( + self.semi_terminated(StmtKind::Rickroll)?, + start..self.lexer.span().end + )), Token::Identifier(_) | Token::Char