MCPcopy Index your code
hub / github.com/Shopify/go-lua / checkMatch

Method checkMatch

scanner.go:535–543  ·  view source on GitHub ↗
(what, who rune, where int)

Source from the content-addressed store, hash-verified

533}
534
535func (s *scanner) checkMatch(what, who rune, where int) {
536 if !s.testNext(what) {
537 if where == s.lineNumber {
538 s.errorExpected(what)
539 } else {
540 s.syntaxError(fmt.Sprintf("%s expected (to close %s at line %d)", s.tokenToString(what), s.tokenToString(who), where))
541 }
542 }
543}

Callers 9

constructorMethod · 0.80
functionArgumentsMethod · 0.80
primaryExpressionMethod · 0.80
forStatementMethod · 0.80
ifStatementMethod · 0.80
whileStatementMethod · 0.80
repeatStatementMethod · 0.80
bodyMethod · 0.80
statementMethod · 0.80

Calls 4

testNextMethod · 0.95
errorExpectedMethod · 0.95
syntaxErrorMethod · 0.95
tokenToStringMethod · 0.95

Tested by

no test coverage detected