Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit3f2d72b

Browse files
committed
plpgsql: Rename a variable for clarity
Rename "core_yy_extra_type core_yy" to "core_yy_extra". The previousname was a bit unclear and confusing. The new name matches the nameused elsewhere for the same purpose, for example insrc/backend/parser/gramparse.h.
1 parenta86cfca commit3f2d72b

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

‎src/pl/plpgsql/src/pl_scanner.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ typedef struct
104104

105105
/* The stuff the core lexer needs */
106106
staticcore_yyscan_tyyscanner=NULL;
107-
staticcore_yy_extra_typecore_yy;
107+
staticcore_yy_extra_typecore_yy_extra;
108108

109109
/* The original input string */
110110
staticconstchar*scanorig;
@@ -224,7 +224,7 @@ plpgsql_yylex(void)
224224
push_back_token(tok3,&aux3);
225225
push_back_token(tok2,&aux2);
226226
if (plpgsql_parse_word(aux1.lval.str,
227-
core_yy.scanbuf+aux1.lloc,
227+
core_yy_extra.scanbuf+aux1.lloc,
228228
true,
229229
&aux1.lval.wdatum,
230230
&aux1.lval.word))
@@ -264,7 +264,7 @@ plpgsql_yylex(void)
264264
* non-variable cases.
265265
*/
266266
if (plpgsql_parse_word(aux1.lval.str,
267-
core_yy.scanbuf+aux1.lloc,
267+
core_yy_extra.scanbuf+aux1.lloc,
268268
(!AT_STMT_START(plpgsql_yytoken)||
269269
(tok2=='='||tok2==COLON_EQUALS||
270270
tok2=='[')),
@@ -340,7 +340,7 @@ internal_yylex(TokenAuxData *auxdata)
340340
yyscanner);
341341

342342
/* remember the length of yytext before it gets changed */
343-
yytext=core_yy.scanbuf+auxdata->lloc;
343+
yytext=core_yy_extra.scanbuf+auxdata->lloc;
344344
auxdata->leng=strlen(yytext);
345345

346346
/* Check for << >> and #, which the core considers operators */
@@ -515,7 +515,7 @@ plpgsql_scanner_errposition(int location)
515515
void
516516
plpgsql_yyerror(constchar*message)
517517
{
518-
char*yytext=core_yy.scanbuf+plpgsql_yylloc;
518+
char*yytext=core_yy_extra.scanbuf+plpgsql_yylloc;
519519

520520
if (*yytext=='\0')
521521
{
@@ -603,7 +603,7 @@ void
603603
plpgsql_scanner_init(constchar*str)
604604
{
605605
/* Start up the core scanner */
606-
yyscanner=scanner_init(str,&core_yy,
606+
yyscanner=scanner_init(str,&core_yy_extra,
607607
&ReservedPLKeywords,ReservedPLKeywordTokens);
608608

609609
/*

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp