Commit 0ed291e6 authored by Sergei Golubchik's avatar Sergei Golubchik

cleanup: parser: s/USER/USER_SYM/

parent 0bef3bb8
...@@ -646,7 +646,7 @@ static SYMBOL symbols[] = { ...@@ -646,7 +646,7 @@ static SYMBOL symbols[] = {
{ "UPGRADE", SYM(UPGRADE_SYM)}, { "UPGRADE", SYM(UPGRADE_SYM)},
{ "USAGE", SYM(USAGE)}, { "USAGE", SYM(USAGE)},
{ "USE", SYM(USE_SYM)}, { "USE", SYM(USE_SYM)},
{ "USER", SYM(USER)}, { "USER", SYM(USER_SYM)},
{ "USER_RESOURCES", SYM(RESOURCES)}, { "USER_RESOURCES", SYM(RESOURCES)},
{ "USE_FRM", SYM(USE_FRM)}, { "USE_FRM", SYM(USE_FRM)},
{ "USING", SYM(USING)}, { "USING", SYM(USING)},
...@@ -714,7 +714,7 @@ static SYMBOL sql_functions[] = { ...@@ -714,7 +714,7 @@ static SYMBOL sql_functions[] = {
{ "PERCENT_RANK", SYM(PERCENT_RANK_SYM)}, { "PERCENT_RANK", SYM(PERCENT_RANK_SYM)},
{ "RANK", SYM(RANK_SYM)}, { "RANK", SYM(RANK_SYM)},
{ "ROW_NUMBER", SYM(ROW_NUMBER_SYM)}, { "ROW_NUMBER", SYM(ROW_NUMBER_SYM)},
{ "SESSION_USER", SYM(USER)}, { "SESSION_USER", SYM(USER_SYM)},
{ "STD", SYM(STD_SYM)}, { "STD", SYM(STD_SYM)},
{ "STDDEV", SYM(STD_SYM)}, { "STDDEV", SYM(STD_SYM)},
{ "STDDEV_POP", SYM(STD_SYM)}, { "STDDEV_POP", SYM(STD_SYM)},
...@@ -724,7 +724,7 @@ static SYMBOL sql_functions[] = { ...@@ -724,7 +724,7 @@ static SYMBOL sql_functions[] = {
{ "SUBSTRING", SYM(SUBSTRING)}, { "SUBSTRING", SYM(SUBSTRING)},
{ "SUM", SYM(SUM_SYM)}, { "SUM", SYM(SUM_SYM)},
{ "SYSDATE", SYM(SYSDATE)}, { "SYSDATE", SYM(SYSDATE)},
{ "SYSTEM_USER", SYM(USER)}, { "SYSTEM_USER", SYM(USER_SYM)},
{ "TRIM", SYM(TRIM)}, { "TRIM", SYM(TRIM)},
{ "VARIANCE", SYM(VARIANCE_SYM)}, { "VARIANCE", SYM(VARIANCE_SYM)},
{ "VAR_POP", SYM(VARIANCE_SYM)}, { "VAR_POP", SYM(VARIANCE_SYM)},
......
...@@ -1683,7 +1683,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize); ...@@ -1683,7 +1683,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
%token UPDATE_SYM /* SQL-2003-R */ %token UPDATE_SYM /* SQL-2003-R */
%token UPGRADE_SYM %token UPGRADE_SYM
%token USAGE /* SQL-2003-N */ %token USAGE /* SQL-2003-N */
%token USER /* SQL-2003-R */ %token USER_SYM /* SQL-2003-R */
%token USE_FRM %token USE_FRM
%token USE_SYM %token USE_SYM
%token USING /* SQL-2003-R */ %token USING /* SQL-2003-R */
...@@ -2632,7 +2632,7 @@ create: ...@@ -2632,7 +2632,7 @@ create:
Lex->create_view_suid= TRUE; Lex->create_view_suid= TRUE;
} }
view_or_trigger_or_sp_or_event { } view_or_trigger_or_sp_or_event { }
| create_or_replace USER opt_if_not_exists clear_privileges grant_list | create_or_replace USER_SYM opt_if_not_exists clear_privileges grant_list
opt_require_clause opt_resource_options opt_require_clause opt_resource_options
{ {
if (Lex->set_command_with_check(SQLCOM_CREATE_USER, $1 | $3)) if (Lex->set_command_with_check(SQLCOM_CREATE_USER, $1 | $3))
...@@ -2675,7 +2675,7 @@ server_options_list: ...@@ -2675,7 +2675,7 @@ server_options_list:
; ;
server_option: server_option:
USER TEXT_STRING_sys USER_SYM TEXT_STRING_sys
{ {
MYSQL_YYABORT_UNLESS(Lex->server_options.username.str == 0); MYSQL_YYABORT_UNLESS(Lex->server_options.username.str == 0);
Lex->server_options.username= $2; Lex->server_options.username= $2;
...@@ -7289,7 +7289,7 @@ alter: ...@@ -7289,7 +7289,7 @@ alter:
lex->server_options.reset($3); lex->server_options.reset($3);
} OPTIONS_SYM '(' server_options_list ')' { } } OPTIONS_SYM '(' server_options_list ')' { }
/* ALTER USER foo is allowed for MySQL compatibility. */ /* ALTER USER foo is allowed for MySQL compatibility. */
| ALTER opt_if_exists USER clear_privileges grant_list | ALTER opt_if_exists USER_SYM clear_privileges grant_list
opt_require_clause opt_resource_options opt_require_clause opt_resource_options
{ {
Lex->create_info.set($2); Lex->create_info.set($2);
...@@ -8242,7 +8242,7 @@ rename: ...@@ -8242,7 +8242,7 @@ rename:
} }
table_to_table_list table_to_table_list
{} {}
| RENAME USER clear_privileges rename_list | RENAME USER_SYM clear_privileges rename_list
{ {
Lex->sql_command = SQLCOM_RENAME_USER; Lex->sql_command = SQLCOM_RENAME_USER;
} }
...@@ -9654,7 +9654,7 @@ function_call_keyword: ...@@ -9654,7 +9654,7 @@ function_call_keyword:
if ($$ == NULL) if ($$ == NULL)
MYSQL_YYABORT; MYSQL_YYABORT;
} }
| USER '(' ')' | USER_SYM '(' ')'
{ {
$$= new (thd->mem_root) Item_func_user(thd); $$= new (thd->mem_root) Item_func_user(thd);
if ($$ == NULL) if ($$ == NULL)
...@@ -12189,7 +12189,7 @@ drop: ...@@ -12189,7 +12189,7 @@ drop:
lex->set_command(SQLCOM_DROP_PROCEDURE, $3); lex->set_command(SQLCOM_DROP_PROCEDURE, $3);
lex->spname= $4; lex->spname= $4;
} }
| DROP USER opt_if_exists clear_privileges user_list | DROP USER_SYM opt_if_exists clear_privileges user_list
{ {
Lex->set_command(SQLCOM_DROP_USER, $3); Lex->set_command(SQLCOM_DROP_USER, $3);
} }
...@@ -13039,14 +13039,14 @@ show_param: ...@@ -13039,14 +13039,14 @@ show_param:
lex->sql_command= SQLCOM_SHOW_CREATE_TRIGGER; lex->sql_command= SQLCOM_SHOW_CREATE_TRIGGER;
lex->spname= $3; lex->spname= $3;
} }
| CREATE USER | CREATE USER_SYM
{ {
Lex->sql_command= SQLCOM_SHOW_CREATE_USER; Lex->sql_command= SQLCOM_SHOW_CREATE_USER;
if (!(Lex->grant_user= (LEX_USER*)thd->alloc(sizeof(LEX_USER)))) if (!(Lex->grant_user= (LEX_USER*)thd->alloc(sizeof(LEX_USER))))
MYSQL_YYABORT; MYSQL_YYABORT;
Lex->grant_user->user= current_user; Lex->grant_user->user= current_user;
} }
| CREATE USER user | CREATE USER_SYM user
{ {
Lex->sql_command= SQLCOM_SHOW_CREATE_USER; Lex->sql_command= SQLCOM_SHOW_CREATE_USER;
Lex->grant_user= $3; Lex->grant_user= $3;
...@@ -13492,7 +13492,7 @@ kill_expr: ...@@ -13492,7 +13492,7 @@ kill_expr:
{ {
Lex->value_list.push_front($$, thd->mem_root); Lex->value_list.push_front($$, thd->mem_root);
} }
| USER user | USER_SYM user
{ {
Lex->users_list.push_back($2, thd->mem_root); Lex->users_list.push_back($2, thd->mem_root);
Lex->kill_type= KILL_TYPE_USER; Lex->kill_type= KILL_TYPE_USER;
...@@ -14912,7 +14912,7 @@ keyword_sp: ...@@ -14912,7 +14912,7 @@ keyword_sp:
| UNDOFILE_SYM {} | UNDOFILE_SYM {}
| UNKNOWN_SYM {} | UNKNOWN_SYM {}
| UNTIL_SYM {} | UNTIL_SYM {}
| USER {} | USER_SYM {}
| USE_FRM {} | USE_FRM {}
| VARIABLES {} | VARIABLES {}
| VIEW_SYM {} | VIEW_SYM {}
...@@ -15817,7 +15817,7 @@ object_privilege: ...@@ -15817,7 +15817,7 @@ object_privilege:
| SHOW VIEW_SYM { Lex->grant |= SHOW_VIEW_ACL; } | SHOW VIEW_SYM { Lex->grant |= SHOW_VIEW_ACL; }
| CREATE ROUTINE_SYM { Lex->grant |= CREATE_PROC_ACL; } | CREATE ROUTINE_SYM { Lex->grant |= CREATE_PROC_ACL; }
| ALTER ROUTINE_SYM { Lex->grant |= ALTER_PROC_ACL; } | ALTER ROUTINE_SYM { Lex->grant |= ALTER_PROC_ACL; }
| CREATE USER { Lex->grant |= CREATE_USER_ACL; } | CREATE USER_SYM { Lex->grant |= CREATE_USER_ACL; }
| EVENT_SYM { Lex->grant |= EVENT_ACL;} | EVENT_SYM { Lex->grant |= EVENT_ACL;}
| TRIGGER_SYM { Lex->grant |= TRIGGER_ACL; } | TRIGGER_SYM { Lex->grant |= TRIGGER_ACL; }
| CREATE TABLESPACE { Lex->grant |= CREATE_TABLESPACE_ACL; } | CREATE TABLESPACE { Lex->grant |= CREATE_TABLESPACE_ACL; }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment