Skip to content

Commit 1e30760

Browse files
committed
some refactoring
1 parent 04d2b65 commit 1e30760

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/main/jjtree/net/sf/jsqlparser/parser/JSqlParserCC.jjt

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,11 @@ TOKEN: /* SQL Keywords. prefixed with K_ to avoid name clashes */
238238
| <K_TIME_KEY_EXPR : ( "CURRENT_TIMESTAMP" | "CURRENT_TIME" | "CURRENT_DATE" ) ( "()" )?>
239239
}
240240

241+
TOKEN : /* Stuff */
242+
{
243+
<ST_SEMICOLON : ";" >
244+
}
245+
241246
TOKEN : /* Operators */
242247
{
243248
<OP_GREATERTHANEQUALS: ">" (<WHITESPACE>)* "=">
@@ -280,7 +285,7 @@ Statement Statement() #Statement:
280285
{ Statement stm; }
281286
{
282287
stm = SingleStatement()
283-
[";"]
288+
[<ST_SEMICOLON>]
284289
<EOF>
285290
{
286291
return stm;
@@ -333,10 +338,9 @@ Statements Statements() #Statements :
333338
List<Statement> list = new ArrayList<Statement>();
334339
Statement stm; }
335340
{
336-
(";")*
341+
(<ST_SEMICOLON>)*
337342
stm = SingleStatement() { list.add(stm); }
338-
( (";") [ stm = SingleStatement() { list.add(stm); } ] )*
339-
343+
( <ST_SEMICOLON> [ stm = SingleStatement() { list.add(stm); } ] )*
340344
<EOF>
341345

342346
{

0 commit comments

Comments
 (0)