Re: Add custom EXPLAIN options support to auto_explain

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Lukas Fittl <lukas(at)fittl(dot)com>
Cc: Matheus Alcantara <matheusssilv97(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Add custom EXPLAIN options support to auto_explain
Date: 2026-04-06 15:22:42
Message-ID: CA+TgmobjYqq-s10BHtDDwBZtKFrN1WjK75Sai95=Lq77hWpXsQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Apr 3, 2026 at 10:09 PM Lukas Fittl <lukas(at)fittl(dot)com> wrote:
> Maybe make it clear in the comment that the return value is
> unterminated (e.g. "The return value is the unterminated identifier"),
> i.e. caller is responsible for setting the null byte based on endp.
>
> Otherwise 0001 looks good.

Thanks for the review, but I don't agree with that proposed change. To
me, it seems too much like insisting that a function must document the
things it doesn't do. Granted, saying "this function doesn't overwrite
*endp" is a much more reasonable thing to document than "this function
doesn't try to compute pi to 3,141,593 decimal places," because the
latter is less likely to be something that the user would expect it to
do. But I feel like the comment is clear enough as it is, so I've
committed the patch without change. If more votes in favor of
adjusting the comment emerge, we can certainly reconsider.

--
Robert Haas
EDB: http://www.enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jelte Fennema-Nio 2026-04-06 15:24:06 Re: pg_get__*_ddl consolidation
Previous Message David G. Johnston 2026-04-06 15:15:51 Re: PG 19 release notes and authors