From: | Mark Dilger <hornschnorter(at)gmail(dot)com> |
---|---|
To: | Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> |
Cc: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Add some const decorations to prototypes |
Date: | 2017-11-01 18:27:28 |
Message-ID: | 1ED3A51F-E29E-4499-8E04-0F0E895CF275@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> On Oct 31, 2017, at 7:46 AM, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> wrote:
>
> Here is a patch that adds const decorations to many char * arguments in
> functions. It should have no impact otherwise; there are very few code
> changes caused by it. Some functions have a strtol()-like behavior
> where they take in a const char * and return a pointer into that as
> another argument. In those cases, I added a cast or two.
>
> Generally, I find these const decorations useful as easy function
> documentation.
+1
I submitted something similar a while back and got into a back and forth
discussion with Tom about it. Anyone interested could take a look at
https://www.postgresql.org/message-id/ACF3A030-E3D5-4E68-B744-184E11DE68F3%40gmail.com
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2017-11-01 18:47:29 | Re: [PATCH] Pageinspect - add functions on GIN and GiST indexes from gevel |
Previous Message | David Christensen | 2017-11-01 18:27:06 | Re: [PATCH] Add two-arg for of current_setting(NAME, FALLBACK) |