From 6f612b9c57e5d3f0512f2b71a5fe52f1e4b1b009 Mon Sep 17 00:00:00 2001 From: Dominik Holland Date: Mon, 5 Jul 2021 19:20:30 +0200 Subject: Disable the antlr runtim version check The current Lexer and Parser code also works with the latest version of antlr. We rely on the CI to detect any future problems. --- qface/idl/parser/TLexer.py | 4 +++- qface/idl/parser/TParser.py | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/qface/idl/parser/TLexer.py b/qface/idl/parser/TLexer.py index e8ce49a..efcbc1e 100644 --- a/qface/idl/parser/TLexer.py +++ b/qface/idl/parser/TLexer.py @@ -230,7 +230,9 @@ class TLexer(Lexer): def __init__(self, input=None, output:TextIO = sys.stdout): super().__init__(input, output) - self.checkVersion("4.7.1") + # Disable the version check for now as although there is a mismatch the Lexer seems to work fine. + # Rely on the weekly CI to make sure this keeps working also with later antlr versions. + # self.checkVersion("4.7.1") self._interp = LexerATNSimulator(self, self.atn, self.decisionsToDFA, PredictionContextCache()) self._actions = None self._predicates = None diff --git a/qface/idl/parser/TParser.py b/qface/idl/parser/TParser.py index 4b411a9..be85f81 100644 --- a/qface/idl/parser/TParser.py +++ b/qface/idl/parser/TParser.py @@ -280,7 +280,9 @@ class TParser ( Parser ): def __init__(self, input:TokenStream, output:TextIO = sys.stdout): super().__init__(input, output) - self.checkVersion("4.7.1") + # Disable the version check for now as although there is a mismatch the Lexer seems to work fine. + # Rely on the weekly CI to make sure this keeps working also with later antlr versions. + # self.checkVersion("4.7.1") self._interp = ParserATNSimulator(self, self.atn, self.decisionsToDFA, self.sharedContextCache) self._predicates = None -- cgit v1.2.1