MCPcopy Create free account
hub / github.com/cel-expr/cel-go / checkAttempts

Method checkAttempts

parser/parser.go:299–309  ·  view source on GitHub ↗
(recognizer antlr.Parser)

Source from the content-addressed store, hash-verified

297}
298
299func (rl *recoveryLimitErrorStrategy) checkAttempts(recognizer antlr.Parser) {
300 if rl.recoveryAttempts == rl.errorRecoveryLimit {
301 rl.recoveryAttempts++
302 msg := fmt.Sprintf("error recovery attempt limit exceeded: %d", rl.errorRecoveryLimit)
303 recognizer.NotifyErrorListeners(msg, nil, nil)
304 panic(&recoveryLimitError{
305 message: msg,
306 })
307 }
308 rl.recoveryAttempts++
309}
310
311var _ antlr.ErrorStrategy = &recoveryLimitErrorStrategy{}
312

Callers 2

RecoverMethod · 0.95
RecoverInlineMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected