pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Simplify genbki.pl's data quoting rules.
Date: Tue, 17 Apr 2018 22:29:26 +0000
Message-ID: <E1f8Z6M-0000ji-G3@gemulon.postgresql.org> (raw)

Simplify genbki.pl's data quoting rules.

During the bootstrap data format conversion, it seemed important for
verifiability's sake that the generated postgres.bki file stayed the same
as before.  That resulted in adding a bunch of ad-hoc rules about when to
quote emitted data values, to match previous manual decisions that had
often quoted values unnecessarily.  Now that the conversion is complete,
it seems fine to remove all those ad-hoc rules.  The net actual effect on
the current contents of postgres.bki is that some fields that had been
quoted despite containing only digits or only "-" lose their unnecessary
quotes.

Also, now that genbki.pl will always quote values containing a backslash,
there's no need for bootscanner.l to allow unquoted octal escapes;
so simplify its production for "id" by removing that possibility.

John Naylor, slightly modified by me

Discussion: https://postgr.es/m/CAJVSVGUNao=-Q2-vAN3PYcdF5tnL5JAHwGwzZGuYHtq+Mk_9ng@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/e90d4ddc639aac7a7217ebc670ad6e49eaeddbf9

Modified Files
--------------
src/backend/bootstrap/bootscanner.l |  3 +--
src/backend/catalog/genbki.pl       | 28 ++++++----------------------
2 files changed, 7 insertions(+), 24 deletions(-)



Message-ID: <E1f8Z6M-0000ji-G3@gemulon.postgresql.org>
Permalink:  ../E1f8Z6M-0000ji-G3@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1f8Z6M-0000ji-G3@gemulon.postgresql.org

 · 

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 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: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Simplify genbki.pl's data quoting rules.
  In-Reply-To: <E1f8Z6M-0000ji-G3@gemulon.postgresql.org>
  References: <E1f8Z6M-0000ji-G3@gemulon.postgresql.org>

* 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