aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/jsonpath_scan.l
diff options
context:
space:
mode:
authorAlexander Korotkov <akorotkov@postgresql.org>2019-03-19 13:34:16 +0300
committerAlexander Korotkov <akorotkov@postgresql.org>2019-03-19 13:40:55 +0300
commit75c57058b0f5d511a9d80ddfab68a761229d68ea (patch)
tree758c4a8049a5364bca60e0af070726f152c8dacd /src/backend/utils/adt/jsonpath_scan.l
parent590a87025b0aa9ebca53c7b71ddf036e5acd8f08 (diff)
downloadpostgresql-75c57058b0f5d511a9d80ddfab68a761229d68ea.tar.gz
postgresql-75c57058b0f5d511a9d80ddfab68a761229d68ea.zip
Rename typedef in jsonpath_scan.l from "keyword" to "JsonPathKeyword"
Typedef name should be both unique and non-intersect with variable names across all the sources. That makes both pg_indent and debuggers happy. Discussion: https://postgr.es/m/23865.1552936099%40sss.pgh.pa.us
Diffstat (limited to 'src/backend/utils/adt/jsonpath_scan.l')
-rw-r--r--src/backend/utils/adt/jsonpath_scan.l18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/backend/utils/adt/jsonpath_scan.l b/src/backend/utils/adt/jsonpath_scan.l
index c3208169601..eca34411c90 100644
--- a/src/backend/utils/adt/jsonpath_scan.l
+++ b/src/backend/utils/adt/jsonpath_scan.l
@@ -282,20 +282,20 @@ jsonpath_yyerror(JsonPathParseResult **result, const char *message)
}
}
-typedef struct keyword
+typedef struct JsonPathKeyword
{
int16 len;
bool lowercase;
int val;
- const char *keyword;
-} keyword;
+ const char *keyword;
+} JsonPathKeyword;
/*
* Array of key words should be sorted by length and then
* alphabetical order
*/
-static const keyword keywords[] = {
+static const JsonPathKeyword keywords[] = {
{ 2, false, IS_P, "is"},
{ 2, false, TO_P, "to"},
{ 3, false, ABS_P, "abs"},
@@ -322,11 +322,11 @@ static const keyword keywords[] = {
static int
checkSpecialVal()
{
- int res = IDENT_P;
- int diff;
- const keyword *StopLow = keywords,
- *StopHigh = keywords + lengthof(keywords),
- *StopMiddle;
+ int res = IDENT_P;
+ int diff;
+ const JsonPathKeyword *StopLow = keywords,
+ *StopHigh = keywords + lengthof(keywords),
+ *StopMiddle;
if (scanstring.len > keywords[lengthof(keywords) - 1].len)
return res;