(localctx, state, ruleIndex)
| 432 | |
| 433 | // Like {@link //enterRule} but for recursive rules. |
| 434 | pushNewRecursionContext(localctx, state, ruleIndex) { |
| 435 | const previous = this._ctx; |
| 436 | previous.parentCtx = localctx; |
| 437 | previous.invokingState = state; |
| 438 | previous.stop = this._input.LT(-1); |
| 439 | |
| 440 | this._ctx = localctx; |
| 441 | this._ctx.start = previous.start; |
| 442 | if (this.buildParseTrees) { |
| 443 | this._ctx.addChild(previous); |
| 444 | } |
| 445 | this.triggerEnterRuleEvent(); // simulates rule entry for left-recursive rules |
| 446 | } |
| 447 | |
| 448 | unrollRecursionContexts(parentCtx) { |
| 449 | this._precedenceStack.pop(); |
nothing calls this directly
no test coverage detected