()
| 5201 | } |
| 5202 | |
| 5203 | func (p *GScriptParser) Statement() (localctx IStatementContext) { |
| 5204 | localctx = NewStatementContext(p, p.GetParserRuleContext(), p.GetState()) |
| 5205 | p.EnterRule(localctx, 56, GScriptParserRULE_statement) |
| 5206 | var _la int |
| 5207 | |
| 5208 | defer func() { |
| 5209 | p.ExitRule() |
| 5210 | }() |
| 5211 | |
| 5212 | defer func() { |
| 5213 | if err := recover(); err != nil { |
| 5214 | if v, ok := err.(antlr.RecognitionException); ok { |
| 5215 | localctx.SetException(v) |
| 5216 | p.GetErrorHandler().ReportError(p, v) |
| 5217 | p.GetErrorHandler().Recover(p, v) |
| 5218 | } else { |
| 5219 | panic(err) |
| 5220 | } |
| 5221 | } |
| 5222 | }() |
| 5223 | |
| 5224 | p.SetState(333) |
| 5225 | p.GetErrorHandler().Sync(p) |
| 5226 | switch p.GetInterpreter().AdaptivePredict(p.GetTokenStream(), 36, p.GetParserRuleContext()) { |
| 5227 | case 1: |
| 5228 | localctx = NewStmBlockLabelContext(p, localctx) |
| 5229 | p.EnterOuterAlt(localctx, 1) |
| 5230 | { |
| 5231 | p.SetState(297) |
| 5232 | |
| 5233 | var _x = p.Block() |
| 5234 | |
| 5235 | localctx.(*StmBlockLabelContext).blockLabel = _x |
| 5236 | } |
| 5237 | |
| 5238 | case 2: |
| 5239 | localctx = NewStmIfElseContext(p, localctx) |
| 5240 | p.EnterOuterAlt(localctx, 2) |
| 5241 | { |
| 5242 | p.SetState(298) |
| 5243 | p.Match(GScriptParserIF) |
| 5244 | } |
| 5245 | { |
| 5246 | p.SetState(299) |
| 5247 | p.ParExpression() |
| 5248 | } |
| 5249 | { |
| 5250 | p.SetState(300) |
| 5251 | p.Statement() |
| 5252 | } |
| 5253 | p.SetState(303) |
| 5254 | p.GetErrorHandler().Sync(p) |
| 5255 | |
| 5256 | if p.GetInterpreter().AdaptivePredict(p.GetTokenStream(), 32, p.GetParserRuleContext()) == 1 { |
| 5257 | { |
| 5258 | p.SetState(301) |
| 5259 | p.Match(GScriptParserELSE) |
| 5260 | } |
no test coverage detected