Skip to content
Snippets Groups Projects
Commit 42cb5bb2 authored by gmantele's avatar gmantele
Browse files

[ADQL] Complete the commit on the re-compilation of the parser

(005fc622). The position of a TokenMgrError
was not there anymore.
parent 708d175f
No related branches found
No related tags found
No related merge requests found
/* Generated By:JavaCC: Do not edit this line. Token.java Version 6.0 */ /* Generated By:JavaCC: Do not edit this line. Token.java Version 6.0 */
/* JavaCCOptions:TOKEN_EXTENDS=,KEEP_LINE_COL=null,SUPPORT_CLASS_VISIBILITY_PUBLIC=true */ /* JavaCCOptions:TOKEN_EXTENDS=,KEEP_LINE_COL=null,SUPPORT_CLASS_VISIBILITY_PUBLIC=true
*
* Modified by Grégory Mantelet (CDS), on March 2017
* Modification: addition of position (line and column) in the original text.
* /!\ DO NOT RE-GENERATE THIS FILE /!\
* In case of re-generation, replace it by
* Token.java.backup (but maybe after a diff
* in case of significant modifications have been done
* by a new version of JavaCC).
*/
package adql.parser; package adql.parser;
/** /**
......
/* Generated By:JavaCC: Do not edit this line. Token.java Version 6.0 */ /* Generated By:JavaCC: Do not edit this line. Token.java Version 6.0 */
/* JavaCCOptions:TOKEN_EXTENDS=,KEEP_LINE_COL=null,SUPPORT_CLASS_VISIBILITY_PUBLIC=true */ /* JavaCCOptions:TOKEN_EXTENDS=,KEEP_LINE_COL=null,SUPPORT_CLASS_VISIBILITY_PUBLIC=true
*
* Modified by Grégory Mantelet (CDS), on March 2017
* Modification: addition of position (line and column) in the original text.
* /!\ DO NOT RE-GENERATE THIS FILE /!\
* In case of re-generation, replace it by
* Token.java.backup (but maybe after a diff
* in case of significant modifications have been done
* by a new version of JavaCC).
*/
package adql.parser; package adql.parser;
/** /**
......
/* Generated By:JavaCC: Do not edit this line. TokenMgrError.java Version 6.0 */ /* Generated By:JavaCC: Do not edit this line. TokenMgrError.java Version 6.0 */
/* JavaCCOptions: */ /* JavaCCOptions:
*
* Modified by Grégory Mantelet (CDS), on April 2017
* Modification: addition of position (line and column) in the original text.
* /!\ DO NOT RE-GENERATE THIS FILE /!\
* In case of re-generation, replace it by
* TokenMgrError.java.backup (but maybe after a diff
* in case of significant modifications have been done
* by a new version of JavaCC).
*/
package adql.parser; package adql.parser;
/** Token Manager Error. */ /** Token Manager Error. */
...@@ -42,6 +51,12 @@ public class TokenMgrError extends Error { ...@@ -42,6 +51,12 @@ public class TokenMgrError extends Error {
*/ */
int errorCode; int errorCode;
/** Indicates the line at which the error occurs. */
int errorLine = -1;
/** Indicates the column at which the error occurs. */
int errorColumn = -1;
/** /**
* Replaces unprintable characters by their escaped (or unicode escaped) * Replaces unprintable characters by their escaped (or unicode escaped)
* equivalents in the given string * equivalents in the given string
...@@ -120,6 +135,24 @@ public class TokenMgrError extends Error { ...@@ -120,6 +135,24 @@ public class TokenMgrError extends Error {
return super.getMessage(); return super.getMessage();
} }
/**
* Gets the line at which this error occurs.
*
* @return Error line or <code>-1</code> if unknown.
*/
public final int getErrorLine(){
return errorLine;
}
/**
* Gets the column at which this error occurs.
*
* @return Error column or <code>-1</code> if unknown.
*/
public final int getErrorColumn(){
return errorColumn;
}
/* /*
* Constructors of various flavors follow. * Constructors of various flavors follow.
*/ */
...@@ -136,6 +169,8 @@ public class TokenMgrError extends Error { ...@@ -136,6 +169,8 @@ public class TokenMgrError extends Error {
/** Full Constructor. */ /** Full Constructor. */
public TokenMgrError(boolean EOFSeen, int lexState, int errorLine, int errorColumn, String errorAfter, char curChar, int reason){ public TokenMgrError(boolean EOFSeen, int lexState, int errorLine, int errorColumn, String errorAfter, char curChar, int reason){
this(LexicalError(EOFSeen, lexState, errorLine, errorColumn, errorAfter, curChar), reason); this(LexicalError(EOFSeen, lexState, errorLine, errorColumn, errorAfter, curChar), reason);
this.errorLine = errorLine;
this.errorColumn = errorColumn;
} }
} }
/* JavaCC - OriginalChecksum=f63fc7c10226c13ff5a304e2fb1ae182 (do not edit this line) */ /* JavaCC - OriginalChecksum=f63fc7c10226c13ff5a304e2fb1ae182 (do not edit this line) */
/* Generated By:JavaCC: Do not edit this line. TokenMgrError.java Version 6.0 */ /* Generated By:JavaCC: Do not edit this line. TokenMgrError.java Version 6.0 */
/* JavaCCOptions: */ /* JavaCCOptions:
*
* Modified by Gr&eacute;gory Mantelet (CDS), on April 2017
* Modification: addition of position (line and column) in the original text.
* /!\ DO NOT RE-GENERATE THIS FILE /!\
* In case of re-generation, replace it by
* TokenMgrError.java.backup (but maybe after a diff
* in case of significant modifications have been done
* by a new version of JavaCC).
*/
package adql.parser; package adql.parser;
/** Token Manager Error. */ /** Token Manager Error. */
...@@ -42,6 +51,12 @@ public class TokenMgrError extends Error { ...@@ -42,6 +51,12 @@ public class TokenMgrError extends Error {
*/ */
int errorCode; int errorCode;
/** Indicates the line at which the error occurs. */
int errorLine = -1;
/** Indicates the column at which the error occurs. */
int errorColumn = -1;
/** /**
* Replaces unprintable characters by their escaped (or unicode escaped) * Replaces unprintable characters by their escaped (or unicode escaped)
* equivalents in the given string * equivalents in the given string
...@@ -120,6 +135,24 @@ public class TokenMgrError extends Error { ...@@ -120,6 +135,24 @@ public class TokenMgrError extends Error {
return super.getMessage(); return super.getMessage();
} }
/**
* Gets the line at which this error occurs.
*
* @return Error line or <code>-1</code> if unknown.
*/
public final int getErrorLine(){
return errorLine;
}
/**
* Gets the column at which this error occurs.
*
* @return Error column or <code>-1</code> if unknown.
*/
public final int getErrorColumn(){
return errorColumn;
}
/* /*
* Constructors of various flavors follow. * Constructors of various flavors follow.
*/ */
...@@ -136,6 +169,8 @@ public class TokenMgrError extends Error { ...@@ -136,6 +169,8 @@ public class TokenMgrError extends Error {
/** Full Constructor. */ /** Full Constructor. */
public TokenMgrError(boolean EOFSeen, int lexState, int errorLine, int errorColumn, String errorAfter, char curChar, int reason){ public TokenMgrError(boolean EOFSeen, int lexState, int errorLine, int errorColumn, String errorAfter, char curChar, int reason){
this(LexicalError(EOFSeen, lexState, errorLine, errorColumn, errorAfter, curChar), reason); this(LexicalError(EOFSeen, lexState, errorLine, errorColumn, errorAfter, curChar), reason);
this.errorLine = errorLine;
this.errorColumn = errorColumn;
} }
} }
/* JavaCC - OriginalChecksum=f63fc7c10226c13ff5a304e2fb1ae182 (do not edit this line) */ /* JavaCC - OriginalChecksum=f63fc7c10226c13ff5a304e2fb1ae182 (do not edit this line) */
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment