Re: improved DefElem list processing

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: improved DefElem list processing
Date: 2016-09-10 11:25:14
Message-ID: a1308c03-e682-2997-22d9-ecca54e66b22@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 8/22/16 10:28 AM, Alvaro Herrera wrote:
> Peter Eisentraut wrote:
>
>> I'm not happy that utils/acl.h has prototypes for aclchk.c, because
>> acl.h is included all over the place. Perhaps I should make a
>> src/include/catalog/aclchk.c to clean that up.
>
> I've been bothered by that too in the past. +1 for the cleanup.

Here is a patch for that.

It didn't quite achieve the elegance I was hoping for. Most uses of
acl.h actually use aclchk.c functions, and the new aclchk.h must include
acl.h, so basically you end up just changing most includes of acl.h to
aclchk.h while still effectively including acl.h everywhere. But I
think having one header file serve two separate .c files is still a
confusing pattern that is worth cleaning up.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment Content-Type Size
aclchk-split.patch text/x-patch 43.6 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2016-09-10 11:32:21 Re: Re: [COMMITTERS] pgsql: Change the way that LWLocks for extensions are allocated.
Previous Message Peter Eisentraut 2016-09-10 11:17:41 Re: pg_sequence catalog