From 200e10c469ea37fa1696b75f00dd6ffecfce8930 Mon Sep 17 00:00:00 2001 From: hieunguyen2211 <52429592+hieunguyen2211@users.noreply.github.com> Date: Tue, 5 Sep 2023 16:22:44 +0700 Subject: [PATCH] Export DefaultErrorStrategy (#4278) Signed-off-by: hdpnguyen Co-authored-by: hdpnguyen --- runtime/JavaScript/src/antlr4/error/DefaultErrorStrategy.d.ts | 2 +- runtime/JavaScript/src/antlr4/index.node.js | 3 ++- runtime/JavaScript/src/antlr4/index.web.js | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/runtime/JavaScript/src/antlr4/error/DefaultErrorStrategy.d.ts b/runtime/JavaScript/src/antlr4/error/DefaultErrorStrategy.d.ts index 8396808b05..a67795bc12 100644 --- a/runtime/JavaScript/src/antlr4/error/DefaultErrorStrategy.d.ts +++ b/runtime/JavaScript/src/antlr4/error/DefaultErrorStrategy.d.ts @@ -16,7 +16,7 @@ export declare class DefaultErrorStrategy implements ErrorStrategy { sync(recognizer: Parser): void; - inErrorRecoveryMode(recognizer: Parser): void; + inErrorRecoveryMode(recognizer: Parser): boolean; beginErrorCondition(recognizer: Parser): void; diff --git a/runtime/JavaScript/src/antlr4/index.node.js b/runtime/JavaScript/src/antlr4/index.node.js index 6f22b4ad6c..b54aa2ccdf 100644 --- a/runtime/JavaScript/src/antlr4/index.node.js +++ b/runtime/JavaScript/src/antlr4/index.node.js @@ -34,6 +34,7 @@ import RecognitionException from "./error/RecognitionException.js"; import FailedPredicateException from "./error/FailedPredicateException.js"; import NoViableAltException from "./error/NoViableAltException.js"; import BailErrorStrategy from "./error/BailErrorStrategy.js"; +import DefaultErrorStrategy from "./error/DefaultErrorStrategy.js"; import Interval from './misc/Interval.js'; import IntervalSet from './misc/IntervalSet.js'; import ParseTreeListener from "./tree/ParseTreeListener.js"; @@ -55,6 +56,6 @@ export { Token, CommonToken, CharStreams, CharStream, InputStream, FileStream, CommonTokenStream, Lexer, Parser, RuleNode, TerminalNode, ParseTreeWalker, RuleContext, ParserRuleContext, Interval, IntervalSet, PredictionMode, LL1Analyzer, ParseTreeListener, ParseTreeVisitor, ATN, ATNDeserializer, PredictionContextCache, LexerATNSimulator, ParserATNSimulator, DFA, - RecognitionException, NoViableAltException, FailedPredicateException, ErrorListener, DiagnosticErrorListener, BailErrorStrategy, + RecognitionException, NoViableAltException, FailedPredicateException, ErrorListener, DiagnosticErrorListener, BailErrorStrategy, DefaultErrorStrategy, arrayToString } diff --git a/runtime/JavaScript/src/antlr4/index.web.js b/runtime/JavaScript/src/antlr4/index.web.js index 0429a6689f..6361803b1e 100644 --- a/runtime/JavaScript/src/antlr4/index.web.js +++ b/runtime/JavaScript/src/antlr4/index.web.js @@ -33,6 +33,7 @@ import RecognitionException from "./error/RecognitionException.js"; import FailedPredicateException from "./error/FailedPredicateException.js"; import NoViableAltException from "./error/NoViableAltException.js"; import BailErrorStrategy from "./error/BailErrorStrategy.js"; +import DefaultErrorStrategy from "./error/DefaultErrorStrategy.js"; import Interval from './misc/Interval.js'; import IntervalSet from './misc/IntervalSet.js'; import ParseTreeListener from "./tree/ParseTreeListener.js"; @@ -54,6 +55,6 @@ export { Token, CommonToken, CharStreams, CharStream, InputStream, CommonTokenStream, Lexer, Parser, RuleNode, TerminalNode, ParseTreeWalker, RuleContext, ParserRuleContext, Interval, IntervalSet, PredictionMode, LL1Analyzer, ParseTreeListener, ParseTreeVisitor, ATN, ATNDeserializer, PredictionContextCache, LexerATNSimulator, ParserATNSimulator, DFA, - RecognitionException, NoViableAltException, FailedPredicateException, ErrorListener, DiagnosticErrorListener, BailErrorStrategy, + RecognitionException, NoViableAltException, FailedPredicateException, ErrorListener, DiagnosticErrorListener, BailErrorStrategy, DefaultErrorStrategy, arrayToString }