aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Paquier <michael@paquier.xyz>2025-03-26 09:06:36 +0900
committerMichael Paquier <michael@paquier.xyz>2025-03-26 09:06:36 +0900
commit27ee6ede6bc9ee287f321d396c5c777083d40ecd (patch)
treed6f74638484685210fe94292c313d3fdb99eb197
parentcb36f8ec2124b0c495da057a2f55735fe858be0e (diff)
downloadpostgresql-27ee6ede6bc9ee287f321d396c5c777083d40ecd.tar.gz
postgresql-27ee6ede6bc9ee287f321d396c5c777083d40ecd.zip
Fix two issues with custom_query_jumble in gen_node_support.pl
A node field marked with custom_query_jumble and query_jumble_ignore would generate some code of a custom routine. The script is changed so as custom_query_jumble behaves like the other options in this case, query_jumble_ignore taking priority, with no code generated. A comment related to the code generated for node types was misplaced. Thinkos introduced in 5ac462e2b7ac. Reported-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion: https://postgr.es/m/1324036.1742945060@sss.pgh.pa.us
-rw-r--r--src/backend/nodes/gen_node_support.pl6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/nodes/gen_node_support.pl b/src/backend/nodes/gen_node_support.pl
index 40994b53fb2..f6229089cd1 100644
--- a/src/backend/nodes/gen_node_support.pl
+++ b/src/backend/nodes/gen_node_support.pl
@@ -1309,16 +1309,16 @@ _jumble${n}(JumbleState *jstate, Node *node)
}
}
- # node type
if ($query_jumble_custom)
{
# Custom function that applies to one field of a node.
- print $jff "\tJUMBLE_CUSTOM($n, $f);\n";
+ print $jff "\tJUMBLE_CUSTOM($n, $f);\n"
+ unless $query_jumble_ignore;
}
elsif (($t =~ /^(\w+)\*$/ or $t =~ /^struct\s+(\w+)\*$/)
and elem $1, @node_types)
{
- # Squash constants if requested.
+ # Node type. Squash constants if requested.
if ($query_jumble_squash)
{
print $jff "\tJUMBLE_ELEMENTS($f);\n"