()
| 1466 | } |
| 1467 | |
| 1468 | func (p *GScriptParser) FunctionBody() (localctx IFunctionBodyContext) { |
| 1469 | localctx = NewFunctionBodyContext(p, p.GetParserRuleContext(), p.GetState()) |
| 1470 | p.EnterRule(localctx, 12, GScriptParserRULE_functionBody) |
| 1471 | |
| 1472 | defer func() { |
| 1473 | p.ExitRule() |
| 1474 | }() |
| 1475 | |
| 1476 | defer func() { |
| 1477 | if err := recover(); err != nil { |
| 1478 | if v, ok := err.(antlr.RecognitionException); ok { |
| 1479 | localctx.SetException(v) |
| 1480 | p.GetErrorHandler().ReportError(p, v) |
| 1481 | p.GetErrorHandler().Recover(p, v) |
| 1482 | } else { |
| 1483 | panic(err) |
| 1484 | } |
| 1485 | } |
| 1486 | }() |
| 1487 | |
| 1488 | p.SetState(140) |
| 1489 | p.GetErrorHandler().Sync(p) |
| 1490 | |
| 1491 | switch p.GetTokenStream().LA(1) { |
| 1492 | case GScriptParserLBRACE: |
| 1493 | p.EnterOuterAlt(localctx, 1) |
| 1494 | { |
| 1495 | p.SetState(138) |
| 1496 | p.Block() |
| 1497 | } |
| 1498 | |
| 1499 | case GScriptParserT__0: |
| 1500 | p.EnterOuterAlt(localctx, 2) |
| 1501 | { |
| 1502 | p.SetState(139) |
| 1503 | p.Match(GScriptParserT__0) |
| 1504 | } |
| 1505 | |
| 1506 | default: |
| 1507 | panic(antlr.NewNoViableAltException(p, nil, nil, nil, nil, nil)) |
| 1508 | } |
| 1509 | |
| 1510 | return localctx |
| 1511 | } |
| 1512 | |
| 1513 | // ITypeTypeOrVoidContext is an interface to support dynamic dispatch. |
| 1514 | type ITypeTypeOrVoidContext interface { |
no test coverage detected