pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Arthur Zakirov <a.zakirov@postgrespro.ru>
To: Dmitry Dolgov <9erthalion6@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: David Steele <david@pgmasters.net>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: [PATCH] Generic type subscripting
Date: Sun, 10 Sep 2017 00:33:49 +0300
Message-ID: <20170909213349.GA17898@arthur.localdomain> (raw)
In-Reply-To: <CA+q6zcVRkCZZSXee42nwjrPL1V3YEcjnhOjQNykxTn0t02Lw4Q@mail.gmail.com>
References: <CA+q6zcVovR+XY4mfk-7oNk-rF91gH0PebnNfuUjuuDsyHjOcVA@mail.gmail.com>
	<CA+q6zcX+HBjSp9nX-SFhmAQ5k7waU4yDnbnyvZPJHy+E+8258A@mail.gmail.com>
	<CA+q6zcUmz_Xa6SQC6-+XH4vNj439r0huXwJR_YK9KBEAW9C3HQ@mail.gmail.com>
	<3939224.Pu1MPp1GC3@zakirov>
	<CA+q6zcXV4Mscao_Z9ypy8rz6QfuPE+-gj2THMi5xXjvQGohFYA@mail.gmail.com>
	<CA+q6zcXW2nn0FAu9iCkn7WWM+OQeCTf2ons-Vp6SfxYHeg+gjw@mail.gmail.com>
	<CA+q6zcVb+ka1vF4RJuhuh9i4fKP4RWwQMpVizq00b-iQXQ42sQ@mail.gmail.com>
	<CA+q6zcVRkCZZSXee42nwjrPL1V3YEcjnhOjQNykxTn0t02Lw4Q@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

On Thu, Sep 07, 2017 at 10:49:54PM +0200, Dmitry Dolgov wrote:
> On 29 August 2017 at 22:42, Dmitry Dolgov <9erthalion6@gmail.com> wrote:
> >
> > To make a review little bit easier I've divided the patch into a few
> smaller parts.
> 
> Apparently I forgot about subscripting for the name data type, so here is a
> small update of the patch.

Thank you for rebasing the patch!

PostgreSQL and documentation with the patch compiles without any errors. All regression tests passed.

But honestly I still cannot say that I agree with *_extract() and *_assign() functions creation way. For example, there is no entry in pg_depend for them (related with pg_type entry).

Because there is no such entry, there is the following bug:

1 - make and install src/tutorial
2 - run src/tutorial/subscripting.sql
3 - run:

=# drop function custom_subscripting_extract(internal);

4 - and we get the error:

=# select data[0] from test_subscripting;
ERROR:  function 0x55deb7911bfd returned NULL

But of course it is only my opinion and I could be wrong.

-- 
Arthur Zakirov
Postgres Professional: http://www.postgrespro.com
Russian Postgres Company


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



view thread (276+ messages)  latest in thread

Message-ID: <20170909213349.GA17898@arthur.localdomain>
Permalink:  ../20170909213349.GA17898@arthur.localdomain/
Also on:    postgresql.org/message-id/20170909213349.GA17898@arthur.localdomain

 · 

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: pgsql-hackers@postgresql.org
  Cc: a.zakirov@postgrespro.ru, 9erthalion6@gmail.com, tgl@sss.pgh.pa.us, david@pgmasters.net, peter.eisentraut@2ndquadrant.com
  Subject: Re: [PATCH] Generic type subscripting
  In-Reply-To: <20170909213349.GA17898@arthur.localdomain>

* 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