From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Jeff Davis <pgsql(at)j-davis(dot)com> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: WIP: Range Types |
Date: | 2011-01-12 02:24:08 |
Message-ID: | AANLkTik6MT_xTZEsemDK+pbdCurbXKngONTRuSZ_iR6x@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Sun, Jan 9, 2011 at 4:03 AM, Jeff Davis <pgsql(at)j-davis(dot)com> wrote:
> It also might be worth figuring out why input functions get the type oid
> and output functions do not. I see this comment above getTypeIOParam():
>
> * As of PostgreSQL 8.1, output functions receive only the value
> itself
> * and not any auxiliary parameters, so the name of this routine is
> now
> * a bit of a misnomer ... it should be
> getTypeInputParam.
>
> So, why was it eliminated?
Good question. The relevant commit is here:
commit 6c412f0605afeb809014553ff7ad28cf9ed5526b
Author: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Date: Sun May 1 18:56:19 2005 +0000
Change CREATE TYPE to require datatype output and send functions to have
only one argument. (Per recent discussion, the option to accept multiple
arguments is pretty useless for user-defined types, and would be a likely
source of security holes if it was used.) Simplify call sites of
output/send functions to not bother passing more than one argument.
...but I don't understand the motivation behind it.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Florian Pflug | 2011-01-12 02:25:24 | Re: pg_depend explained |
Previous Message | Robert Haas | 2011-01-12 02:17:51 | reviewers needed! |