Skip to content

Commit

Permalink
Fixing scanner to parse true correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
patbuc committed Nov 27, 2023
1 parent a5b534a commit 5e85cf7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/compiler/scanner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ impl Scanner {
if self.current - self.start > 1 {
return match self.source[self.start + 1] {
'h' => self.check_keyword(2, 2, "is", TokenType::This),
'r' => self.check_keyword(2, 1, "ue", TokenType::True),
'r' => self.check_keyword(2, 2, "ue", TokenType::True),
_ => TokenType::Identifier,
};
}
Expand Down

0 comments on commit 5e85cf7

Please sign in to comment.