public inbox for [email protected]
help / color / mirror / Atom feedFrom: Tom Lane <[email protected]>
To: Robert Haas <[email protected]>
Cc: Mark Wong <[email protected]>
Cc: Greg Stark <[email protected]>
Cc: Chapman Flack <[email protected]>
Cc: Ashutosh Bapat <[email protected]>
Cc: PostgreSQL Hackers <[email protected]>
Subject: Re: real/float example for testlibpq3
Date: Thu, 16 Jun 2022 15:41:50 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <CA+TgmobLR929aHtOfC=JKqz+qzDxdYo_dssj06TyOpnU+HbT6A@mail.gmail.com>
References: <Yhf70G9OYIKueYZi@workstation-mark-wong>
<CAExHW5tm1FyoLZXdTjdrfRO7ObuoL_p2krc65C5s8D3eWFB50g@mail.gmail.com>
<[email protected]>
<[email protected]>
<[email protected]>
<CAM-w4HM2t7TonV7bz+V27Vvoo0j6hN9-omDo9SHmQ7O58UFYQg@mail.gmail.com>
<YqjH9qGaIixfZXQo@workstation-mark-wong>
<CA+TgmobLR929aHtOfC=JKqz+qzDxdYo_dssj06TyOpnU+HbT6A@mail.gmail.com>
Robert Haas <[email protected]> writes:
> On Tue, Jun 14, 2022 at 1:40 PM Mark Wong <[email protected]> wrote:
>> I've created a function for each data type with the idea that an example
>> for handling a specific data type can be more easily reviewed by looking
>> in a single place.
>> I've added examples for REAL, TIMESTAMP WITHOUT TIME ZONE, and BOOLEAN
>> to try to illustrate how testlibpq3.sql and testlibpq3.c will grow if
>> this is a good way to go.
> I'm not sure that we want to let these test programs grow very large.
> In particular, I don't think we should let ourselves get sucked into
> adding an example for every data type under the sun -- if that's
> wanted, the solution is perhaps to add documentation for the binary
> formats, not hide impromptu documentation inside a test program. But
> doing this much seems OK to me.
Yeah, "hiding impromptu documentation inside a test program" is what
this looks like, and I'm not sure that's a reasonable way to go.
(1) Who's going to think to look in src/test/examples/testlibpq3.c for
documentation of binary formats?
(2) The useful details are likely to get buried in notational and
portability concerns, as I think your build failure illustrates.
(3) I bet few if any packagers install these files, so that the new
info would be unavailable to many people.
I think some new appendix in the main SGML docs would be the appropriate
place if we want to provide real documentation.
regards, tom lane
view thread (19+ messages) latest in thread
reply
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
Subject: Re: real/float example for testlibpq3
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox