From a47be17545281226faa12cefbcdf75755d3c2bef Mon Sep 17 00:00:00 2001 From: Simeon Widdis Date: Wed, 29 Jan 2025 14:45:59 -0800 Subject: [PATCH] Update a comment Signed-off-by: Simeon Widdis --- .../sql/common/antlr/SyntaxAnalysisErrorListener.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/src/main/java/org/opensearch/sql/common/antlr/SyntaxAnalysisErrorListener.java b/common/src/main/java/org/opensearch/sql/common/antlr/SyntaxAnalysisErrorListener.java index a47f6a98b6..46fd29c2c6 100644 --- a/common/src/main/java/org/opensearch/sql/common/antlr/SyntaxAnalysisErrorListener.java +++ b/common/src/main/java/org/opensearch/sql/common/antlr/SyntaxAnalysisErrorListener.java @@ -16,7 +16,7 @@ * information. */ public class SyntaxAnalysisErrorListener extends BaseErrorListener { - // Show the up to this many characters before the offending token in the query. + // Show up to this many characters before the offending token in the query. private static final int CONTEXT_TRUNCATION_THRESHOLD = 20; // Avoid presenting too many alternatives when many are available. private static final int SUGGESTION_TRUNCATION_THRESHOLD = 5; @@ -57,7 +57,7 @@ private String truncateQueryAtOffendingToken(String query, Token offendingToken) private String getDetails(Recognizer recognizer, String msg, RecognitionException e) { if (e == null) { - // As official ANTLR says, e=null means parser was able to recover from the error. + // According to the ANTLR docs, e == null means the parser was able to recover from the error. // In such cases, `msg` includes the raw error information we care about. return msg; }