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

Method Start_

parser/gen/cel_parser.go:378–409  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

376}
377
378func (p *CELParser) Start_() (localctx IStartContext) {
379 localctx = NewStartContext(p, p.GetParserRuleContext(), p.GetState())
380 p.EnterRule(localctx, 0, CELParserRULE_start)
381 p.EnterOuterAlt(localctx, 1)
382 {
383 p.SetState(34)
384
385 var _x = p.Expr()
386
387 localctx.(*StartContext).e = _x
388 }
389 {
390 p.SetState(35)
391 p.Match(CELParserEOF)
392 if p.HasError() {
393 // Recognition error - abort rule
394 goto errorExit
395 }
396 }
397
398errorExit:
399 if p.HasError() {
400 v := p.GetError()
401 localctx.SetException(v)
402 p.GetErrorHandler().ReportError(p, v)
403 p.GetErrorHandler().Recover(p, v)
404 p.SetError(nil)
405 }
406 p.ExitRule()
407 return localctx
408 goto errorExit // Trick to prevent compiler error if the label is not used
409}
410
411// IExprContext is an interface to support dynamic dispatch.
412type IExprContext interface {

Callers 1

parseMethod · 0.95

Calls 8

ExprMethod · 0.95
ReportErrorMethod · 0.80
RecoverMethod · 0.80
NewStartContextFunction · 0.70
GetStateMethod · 0.65
MatchMethod · 0.65
EnterRuleMethod · 0.45
ExitRuleMethod · 0.45

Tested by

no test coverage detected