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@postgresql.org
Subject: pgsql: Get rid of ParseState.p_value_substitute; use a columnref hook i
Date: Sat, 07 Jan 2017 21:02:34 +0000
Message-ID: <E1cPy8I-0007KL-FQ@gemulon.postgresql.org> (raw)
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

Get rid of ParseState.p_value_substitute; use a columnref hook instead.

I noticed that p_value_substitute, which is a single-purpose kluge I added
in 2002 (commit b0422b215), could be replaced by having domainAddConstraint
install a parser hook that looks for the name "value".  The parser hook
code only dates back to 2009, so it's not surprising that we had to kluge
this in 2002, but we can do it more cleanly now.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/7c3abe3c92fd3a14a70bc2f888f936cd6fe28c0f

Modified Files
--------------
src/backend/commands/typecmds.c | 34 +++++++++++++++++++++++++++++++++-
src/backend/parser/parse_expr.c | 21 ---------------------
src/include/parser/parse_node.h |  4 ----
3 files changed, 33 insertions(+), 26 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


Message-ID: <E1cPy8I-0007KL-FQ@gemulon.postgresql.org>
Permalink:  ../E1cPy8I-0007KL-FQ@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1cPy8I-0007KL-FQ@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: Get rid of ParseState.p_value_substitute; use a columnref hook i
  In-Reply-To: <E1cPy8I-0007KL-FQ@gemulon.postgresql.org>
  References: <E1cPy8I-0007KL-FQ@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