MCPcopy Create free account
hub / github.com/aiscriptdev/aiscript / consume_either

Method consume_either

aiscript-lexer/src/lib.rs:861–867  ·  view source on GitHub ↗
(&mut self, k1: TokenType, k2: TokenType, message: &str)

Source from the content-addressed store, hash-verified

859 }
860
861 pub fn consume_either(&mut self, k1: TokenType, k2: TokenType, message: &str) {
862 if self.check_either(k1, k2) {
863 self.advance();
864 return;
865 }
866 self.error_at_current(message);
867 }
868
869 pub fn match_token(&mut self, kind: TokenType) -> bool {
870 if self.check(kind) {

Callers 2

enum_declarationMethod · 0.80
class_declarationMethod · 0.80

Calls 3

check_eitherMethod · 0.80
advanceMethod · 0.80
error_at_currentMethod · 0.80

Tested by

no test coverage detected