From: Fabien COELHO <coelho@cri.ensmp.fr>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Andres Freund <andres@anarazel.de>
Cc: Andrew Dunstan <andrew@dunslane.net>
Cc: PostgreSQL Developers <pgsql-hackers@postgresql.org>
Subject: Re: [COMMITTERS] pgsql: Add missing support for new node fields
Date: Tue, 21 Mar 2017 22:01:48 +0100 (CET)
Message-ID: <alpine.DEB.2.20.1703212154420.22754@lancre> (raw)
In-Reply-To: <CA+TgmoYG7FDtpxcwFosALRZFnzcF5+Gs7=aEr60gC-fHFRvhMQ@mail.gmail.com>
References: <E1cq93r-0004ey-Mp@gemulon.postgresql.org>
<alpine.DEB.2.20.1703210716370.22282@lancre>
<20170321062850.koa557zw3gqyl4lm@alap3.anarazel.de>
<31303.1490108173@sss.pgh.pa.us>
<CA+TgmoYG7FDtpxcwFosALRZFnzcF5+Gs7=aEr60gC-fHFRvhMQ@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Hello Robert,
> IMHO, what would be a lot more useful than something that generates
> {read,equal,copy,out}funcs.c automatically would be something that
> just checks them for trivial errors of omission.
Hmmm. Checking for errors is actually more complicated than generating the
function: basically you have to generate the function, at least
implicitely, then parse the actual functions, then compare the two, then
generate meaningful messages. Thrice the work.
> The idea would be that if you added a field that wasn't supposed to be
> copied, you'd have to add something to copyfuncs.c that said, e.g.
>
> /* NOTCOPIED: mymember */
Yep, I was thinking of maybe use directives added to header files to
handle some special cases, but the real special cases would maybe more
readily turned to manual to keep a simpler generation script.
I do not fancy relying on another representation/language because of Tom's
objection that it would mean another language to learn, and I do not think
that it is desirable in pg.
--
Fabien.
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: coelho@cri.ensmp.fr, robertmhaas@gmail.com, tgl@sss.pgh.pa.us, andres@anarazel.de, andrew@dunslane.net, pgsql-hackers@postgresql.org
Subject: Re: [COMMITTERS] pgsql: Add missing support for new node fields
In-Reply-To: <alpine.DEB.2.20.1703212154420.22754@lancre>
References: <E1cq93r-0004ey-Mp@gemulon.postgresql.org> <alpine.DEB.2.20.1703210716370.22282@lancre> <20170321062850.koa557zw3gqyl4lm@alap3.anarazel.de> <31303.1490108173@sss.pgh.pa.us> <CA+TgmoYG7FDtpxcwFosALRZFnzcF5+Gs7=aEr60gC-fHFRvhMQ@mail.gmail.com> <alpine.DEB.2.20.1703212154420.22754@lancre>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox