MCPcopy Index your code
hub / github.com/sqlc-dev/sqlc / expr

Method expr

internal/engine/sqlite/parser/sqlite_parser.go:13592–14915  ·  view source on GitHub ↗
(_p int)

Source from the content-addressed store, hash-verified

13590}
13591
13592func (p *SQLiteParser) expr(_p int) (localctx IExprContext) {
13593 var _parentctx antlr.ParserRuleContext = p.GetParserRuleContext()
13594
13595 _parentState := p.GetState()
13596 localctx = NewExprContext(p, p.GetParserRuleContext(), _parentState)
13597 var _prevctx IExprContext = localctx
13598 var _ antlr.ParserRuleContext = _prevctx // TODO: To prevent unused variable warning.
13599 _startState := 68
13600 p.EnterRecursionRule(localctx, 68, SQLiteParserRULE_expr, _p)
13601 var _la int
13602
13603 var _alt int
13604
13605 p.EnterOuterAlt(localctx, 1)
13606 p.SetState(1005)
13607 p.GetErrorHandler().Sync(p)
13608 if p.HasError() {
13609 goto errorExit
13610 }
13611
13612 switch p.GetInterpreter().AdaptivePredict(p.BaseParser, p.GetTokenStream(), 129, p.GetParserRuleContext()) {
13613 case 1:
13614 localctx = NewExpr_literalContext(p, localctx)
13615 p.SetParserRuleContext(localctx)
13616 _prevctx = localctx
13617
13618 {
13619 p.SetState(917)
13620 p.Literal_value()
13621 }
13622
13623 case 2:
13624 localctx = NewExpr_bindContext(p, localctx)
13625 p.SetParserRuleContext(localctx)
13626 _prevctx = localctx
13627 {
13628 p.SetState(918)
13629 p.Match(SQLiteParserNUMBERED_BIND_PARAMETER)
13630 if p.HasError() {
13631 // Recognition error - abort rule
13632 goto errorExit
13633 }
13634 }
13635
13636 case 3:
13637 localctx = NewExpr_bindContext(p, localctx)
13638 p.SetParserRuleContext(localctx)
13639 _prevctx = localctx
13640 {
13641 p.SetState(919)
13642 p.Match(SQLiteParserNAMED_BIND_PARAMETER)
13643 if p.HasError() {
13644 // Recognition error - abort rule
13645 goto errorExit
13646 }
13647 }
13648
13649 case 4:

Callers 15

Attach_stmtMethod · 0.95
Create_index_stmtMethod · 0.95
Indexed_columnMethod · 0.95
Column_constraintMethod · 0.95
Table_constraintMethod · 0.95
Create_trigger_stmtMethod · 0.95
Returning_clauseMethod · 0.95
Delete_stmtMethod · 0.95
Delete_stmt_limitedMethod · 0.95
ExprMethod · 0.95
Insert_stmtMethod · 0.95
Upsert_clauseMethod · 0.95

Calls 15

Literal_valueMethod · 0.95
Schema_nameMethod · 0.95
Table_nameMethod · 0.95
Column_nameMethod · 0.95
Unary_operatorMethod · 0.95
Filter_clauseMethod · 0.95
Over_clauseMethod · 0.95
Type_nameMethod · 0.95
Select_stmtMethod · 0.95
Raise_functionMethod · 0.95
Table_function_nameMethod · 0.95

Tested by

no test coverage detected