mirror of
https://github.com/PaddiM8/kalker.git
synced 2024-11-08 08:54:57 +01:00
Lex '**' as power sign
This commit is contained in:
parent
48e94b1cdb
commit
0c454fb6f4
@ -119,6 +119,15 @@ impl<'a> Lexer<'a> {
|
||||
|
||||
self.advance();
|
||||
|
||||
// Handle **
|
||||
if let (TokenKind::Star, Some(c)) = (token.kind, self.peek()) {
|
||||
if *c == '*' {
|
||||
self.advance();
|
||||
|
||||
return build(TokenKind::Power, "", span);
|
||||
}
|
||||
}
|
||||
|
||||
token
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user