MCPcopy
hub / github.com/jquery/esprima / matchKeyword

Method matchKeyword

src/parser.ts:483–485  ·  view source on GitHub ↗
(keyword)

Source from the content-addressed store, hash-verified

481 // Return true if the next token matches the specified keyword
482
483 matchKeyword(keyword) {
484 return this.lookahead.type === Token.Keyword && this.lookahead.value === keyword;
485 }
486
487 // Return true if the next token matches the specified contextual keyword
488 // (where an identifier is sometimes a keyword depending on the context)

Callers 15

parseUnaryExpressionMethod · 0.95
parseLexicalBindingMethod · 0.95
parsePatternMethod · 0.95
parseIfClauseMethod · 0.95
parseIfStatementMethod · 0.95
parseForStatementMethod · 0.95
parseSwitchCaseMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected