This commit is contained in:
Kko 2021-01-25 21:43:30 +08:00
parent 3c67a9d4ea
commit 8bcc12de28
1 changed files with 1 additions and 1 deletions

View File

@ -453,7 +453,7 @@ class Parser (Recognizer):
def getInvokingContext(self, ruleIndex:int):
ctx = self._ctx
while ctx is not None:
if ctx.ruleIndex == ruleIndex:
if ctx.getRuleIndex() == ruleIndex:
return ctx
ctx = ctx.parentCtx
return None