BUG #18901: Bug in Perl-Script "src/backend/nodes/gen_node_support.pl"

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: clemens(dot)ruck(at)t-online(dot)de
Subject: BUG #18901: Bug in Perl-Script "src/backend/nodes/gen_node_support.pl"
Date: 2025-04-22 16:39:46
Message-ID: 18901-424272abe01357e6@postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 18901
Logged by: Clemens Ruck
Email address: clemens(dot)ruck(at)t-online(dot)de
PostgreSQL version: 17.4
Operating system: Ubuntu 22.04
Description:

While implementing some things in my own branch of the Postgres 17.4 branch
(REL_17_STABLE), I encountered a possible bug in the perl script
"src/backend/nodes/gen_node_support.pl". I have a struct declared in
primnodes.h, which had some fields annotated with the pg_node_attr()
modifiers. After that, i had some in-line comments("//") as reminders for my
self, why i put the fields in the struct. The perl-script starts freaking
out if you do that, as the "read input"-loop does not know how to handle
"//"-comments after a struct-field. (Example: "Expr xpr; //Node supertype",
the script never finds the ";" semicolon at the end, because "//"-comments
are never stripped.)

I have no experience in Perl, just wanted to let you know, i encountered
this bug, maybe someone more skilled than me can fix that.

Also, if i may, the error reporting in that script is horrible. What does
"runaway <struct_name> in file "nodes/primnodes.h"." even mean?

Best regards, C

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2025-04-22 17:25:42 Re: BUG #18901: Bug in Perl-Script "src/backend/nodes/gen_node_support.pl"
Previous Message Dave Cramer 2025-04-22 13:40:43 Re: BUG #18872: The current OS X version is not supported