Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[plsql] Fix for #2225 -- rename EMPTY to EMPTY_ to remove symbol conflict #3655

Merged
merged 4 commits into from
Aug 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion sql/plsql/CSharp/PlSqlLexerBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using System.Reflection;
using Antlr4.Runtime;
using Antlr4.Runtime.Misc;
using Antlr4.Runtime;

public class PlSqlLexerBase : Lexer
{
Expand Down
2 changes: 0 additions & 2 deletions sql/plsql/CSharp/PlSqlParserBase.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
using Antlr4.Runtime;
using System;
using System.IO;
using System.Reflection;
using Antlr4.Runtime;
using Antlr4.Runtime.Misc;
using Antlr4.Runtime;

public abstract class PlSqlParserBase : Parser
{
Expand Down
2 changes: 1 addition & 1 deletion sql/plsql/PlSqlLexer.g4
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ ELSIF: 'ELSIF';
EM: 'EM';
EMPTY_BLOB: 'EMPTY_BLOB';
EMPTY_CLOB: 'EMPTY_CLOB';
EMPTY: 'EMPTY';
EMPTY_: 'EMPTY';
ENABLE_ALL: 'ENABLE_ALL';
ENABLE: 'ENABLE';
ENABLE_PARALLEL_DML: 'ENABLE_PARALLEL_DML';
Expand Down
16 changes: 8 additions & 8 deletions sql/plsql/PlSqlParser.g4
Original file line number Diff line number Diff line change
Expand Up @@ -6084,7 +6084,7 @@ unary_logical_expression
logical_operation:
( NULL_
| NAN | PRESENT
| INFINITE | A_LETTER SET | EMPTY
| INFINITE | A_LETTER SET | EMPTY_
| OF TYPE? '(' ONLY? type_spec (',' type_spec)* ')'
)
;
Expand Down Expand Up @@ -6244,9 +6244,9 @@ json_function
| JSON_OBJECT '(' json_object_content ')'
| JSON_OBJECTAGG '(' KEY? expression VALUE expression ((NULL_ | ABSENT) ON NULL_)? (RETURNING ( VARCHAR2 ('(' UNSIGNED_INTEGER ( BYTE | CHAR )? ')')? | CLOB | BLOB ))? STRICT? (WITH UNIQUE KEYS)?')'
| JSON_QUERY '(' expression (FORMAT JSON)? ',' CHAR_STRING json_query_returning_clause json_query_wrapper_clause? json_query_on_error_clause? json_query_on_empty_clause? ')'
| JSON_SERIALIZE '(' CHAR_STRING (RETURNING json_query_return_type)? PRETTY? ASCII? TRUNCATE? ((NULL_ | ERROR | EMPTY (ARRAY | OBJECT)) ON ERROR)? ')'
| JSON_SERIALIZE '(' CHAR_STRING (RETURNING json_query_return_type)? PRETTY? ASCII? TRUNCATE? ((NULL_ | ERROR | EMPTY_ (ARRAY | OBJECT)) ON ERROR)? ')'
| JSON_TRANSFORM '(' expression ',' json_transform_op (',' json_transform_op)* ')'
| JSON_VALUE '(' expression (FORMAT JSON)? (',' CHAR_STRING? json_value_return_clause? ((ERROR | NULL_ | DEFAULT literal)? ON ERROR)? ((ERROR | NULL_ | DEFAULT literal)? ON EMPTY)? json_value_on_mismatch_clause?')')?
| JSON_VALUE '(' expression (FORMAT JSON)? (',' CHAR_STRING? json_value_return_clause? ((ERROR | NULL_ | DEFAULT literal)? ON ERROR)? ((ERROR | NULL_ | DEFAULT literal)? ON EMPTY_)? json_value_on_mismatch_clause?')')?
;

json_object_content
Expand All @@ -6260,7 +6260,7 @@ json_object_entry
;

json_table_clause
: JSON_TABLE '(' expression (FORMAT JSON)? (',' CHAR_STRING)? ((ERROR | NULL_) ON ERROR)? ((EMPTY | NULL_) ON EMPTY)? json_column_clause? ')'
: JSON_TABLE '(' expression (FORMAT JSON)? (',' CHAR_STRING)? ((ERROR | NULL_) ON ERROR)? ((EMPTY_ | NULL_) ON EMPTY_)? json_column_clause? ')'
;

json_array_element
Expand Down Expand Up @@ -6308,11 +6308,11 @@ json_query_wrapper_clause
;

json_query_on_error_clause
: (ERROR | NULL_ | EMPTY | EMPTY ARRAY | EMPTY OBJECT)? ON ERROR
: (ERROR | NULL_ | EMPTY_ | EMPTY_ ARRAY | EMPTY_ OBJECT)? ON ERROR
;

json_query_on_empty_clause
: (ERROR | NULL_ | EMPTY | EMPTY ARRAY | EMPTY OBJECT)? ON EMPTY
: (ERROR | NULL_ | EMPTY_ | EMPTY_ ARRAY | EMPTY_ OBJECT)? ON EMPTY_
;

json_value_return_clause
Expand Down Expand Up @@ -6394,7 +6394,7 @@ other_function
| XMLPI
'(' (NAME identifier | EVALNAME concatenation) (',' concatenation)? ')' ('.' general_element_part)*
| XMLQUERY
'(' concatenation xml_passing_clause? RETURNING CONTENT (NULL_ ON EMPTY)? ')' ('.' general_element_part)*
'(' concatenation xml_passing_clause? RETURNING CONTENT (NULL_ ON EMPTY_)? ')' ('.' general_element_part)*
| XMLROOT
'(' concatenation (',' xmlroot_param_version_part)? (',' xmlroot_param_standalone_part)? ')' ('.' general_element_part)*
| XMLSERIALIZE
Expand Down Expand Up @@ -7884,7 +7884,7 @@ non_reserved_keywords_pre12c
| ELIMINATE_OUTER_JOIN
| EMPTY_BLOB
| EMPTY_CLOB
| EMPTY
| EMPTY_
| ENABLE
| ENABLE_PRESET
| ENCODING
Expand Down
Loading