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

Method checkAttempts

parser/antlr_parser.go:200–210  ·  view source on GitHub ↗
(recognizer antlr.Parser)

Source from the content-addressed store, hash-verified

198}
199
200func (rl *recoveryLimitErrorStrategy) checkAttempts(recognizer antlr.Parser) {
201 if rl.recoveryAttempts == rl.errorRecoveryLimit {
202 rl.recoveryAttempts++
203 msg := fmt.Sprintf("error recovery attempt limit exceeded: %d", rl.errorRecoveryLimit)
204 recognizer.NotifyErrorListeners(msg, nil, nil)
205 panic(&recoveryLimitError{
206 message: msg,
207 })
208 }
209 rl.recoveryAttempts++
210}
211
212var _ antlr.ErrorStrategy = &recoveryLimitErrorStrategy{}
213

Callers 2

RecoverMethod · 0.95
RecoverInlineMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected