MCPcopy
hub / github.com/BloombergGraphics/whatiscode / matchKeyword

Function matchKeyword

scripts/libs/esprima.js:2178–2180  ·  view source on GitHub ↗
(keyword)

Source from the content-addressed store, hash-verified

2176 // Return true if the next token matches the specified keyword
2177
2178 function matchKeyword(keyword) {
2179 return lookahead.type === Token.Keyword && lookahead.value === keyword;
2180 }
2181
2182 // Return true if the next token is an assignment operator
2183

Callers 11

parsePrimaryExpressionFunction · 0.85
parseUnaryExpressionFunction · 0.85
parseLexicalBindingFunction · 0.85
parseIfStatementFunction · 0.85
parseForStatementFunction · 0.85
parseSwitchCaseFunction · 0.85
parseTryStatementFunction · 0.85
parseClassDeclarationFunction · 0.85
parseClassExpressionFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected