diff options
author | Amit Langote <amitlan@postgresql.org> | 2023-07-21 19:15:34 +0900 |
---|---|---|
committer | Amit Langote <amitlan@postgresql.org> | 2023-07-21 19:15:34 +0900 |
commit | 7c7412cae3ea8f8accdec1022969a9360b74f253 (patch) | |
tree | 1ce80497cc5adbe9a33723740a296de929000664 /src/backend/nodes/nodeFuncs.c | |
parent | 97ff8dd02ca788020021cdafb85d77d4fd3f3125 (diff) | |
download | postgresql-7c7412cae3ea8f8accdec1022969a9360b74f253.tar.gz postgresql-7c7412cae3ea8f8accdec1022969a9360b74f253.zip |
Code review for commit b6e1157e7d
b6e1157e7d made some changes to enforce that
JsonValueExpr.formatted_expr is always set and is the expression that
gives a JsonValueExpr its runtime value, but that's not really
apparent from the comments about and the code manipulating
formatted_expr. This commit fixes that.
Per suggestion from Álvaro Herrera.
Discussion: https://postgr.es/m/20230718155313.3wqg6encgt32adqb%40alvherre.pgsql
Diffstat (limited to 'src/backend/nodes/nodeFuncs.c')
-rw-r--r-- | src/backend/nodes/nodeFuncs.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/backend/nodes/nodeFuncs.c b/src/backend/nodes/nodeFuncs.c index c41e6bb984c..503d76aae07 100644 --- a/src/backend/nodes/nodeFuncs.c +++ b/src/backend/nodes/nodeFuncs.c @@ -225,9 +225,7 @@ exprType(const Node *expr) { const JsonValueExpr *jve = (const JsonValueExpr *) expr; - type = exprType((Node *) - (jve->formatted_expr ? jve->formatted_expr : - jve->raw_expr)); + type = exprType((Node *) jve->formatted_expr); } break; case T_JsonConstructorExpr: |