Check if the current token has the given type.
(self, token_type: TokenType)
| 171 | return self.tokens[pos] |
| 172 | |
| 173 | def check(self, token_type: TokenType) -> bool: |
| 174 | """Check if the current token has the given type.""" |
| 175 | return self.current().type == token_type |
| 176 | |
| 177 | def match(self, *types: TokenType) -> bool: |
| 178 | """If current token matches any of the types, consume and return True.""" |