rewrite ExecPartitionCheckEmitError

Lists: pgsql-hackers
From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Pg Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: rewrite ExecPartitionCheckEmitError
Date: 2018-12-06 22:22:21
Message-ID: 20181206222221.g5witbsklvqthjll@alvherre.pgsql
Views: Whole Thread | Raw Message | Download mbox | Resend email
Lists: pgsql-hackers

Just on cleanliness grounds, I propose to rewrite the function in
$SUBJECT. I came across this while reviewing some already-committed
patch for partition pruning, and it's been sitting in my laptop ever
since.

I think the current coding is too convoluted and hard to follow. The
patch makes it much simpler (IMO).

--
Álvaro Herrera

Attachment Content-Type Size
0001-rewrite-ExecPartitionCheckEmitError.patch text/x-diff 2.8 KB

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: rewrite ExecPartitionCheckEmitError
Date: 2018-12-07 20:32:32
Message-ID: CA+TgmobkopYEY3nwjuCBWyWe3ADd1QDkGz0EB1suagXN_qQSUw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Lists: pgsql-hackers

On Thu, Dec 6, 2018 at 5:22 PM Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
> Just on cleanliness grounds, I propose to rewrite the function in
> $SUBJECT. I came across this while reviewing some already-committed
> patch for partition pruning, and it's been sitting in my laptop ever
> since.
>
> I think the current coding is too convoluted and hard to follow. The
> patch makes it much simpler (IMO).

I don't really think this is an improvement, but the only part I
really dislike is s/val_desc/valdsc/. That is surely not an
improvement in readability.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: rewrite ExecPartitionCheckEmitError
Date: 2018-12-28 17:52:24
Message-ID: 201812281752.evicricdva5e@alvherre.pgsql
Views: Whole Thread | Raw Message | Download mbox | Resend email
Lists: pgsql-hackers

On 2018-Dec-07, Robert Haas wrote:

> On Thu, Dec 6, 2018 at 5:22 PM Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
> > Just on cleanliness grounds, I propose to rewrite the function in
> > $SUBJECT. I came across this while reviewing some already-committed
> > patch for partition pruning, and it's been sitting in my laptop ever
> > since.
> >
> > I think the current coding is too convoluted and hard to follow. The
> > patch makes it much simpler (IMO).
>
> I don't really think this is an improvement, but the only part I
> really dislike is s/val_desc/valdsc/. That is surely not an
> improvement in readability.

Point taken; pushed with that change.

--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


From: David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: rewrite ExecPartitionCheckEmitError
Date: 2019-01-01 02:57:37
Message-ID: CAKJS1f8BPRPaFYeiBE0B_QR5m=1mgpbR6qE60oubNaNWOV0ydA@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Lists: pgsql-hackers

On Sat, 29 Dec 2018 at 06:52, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
> Point taken; pushed with that change.

Marking this as committed in the CF app.

--
David Rowley http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services