Re: BUG #19644: byteaout, float8out and float4out are marked IMMUTABLE but depend on GUCs

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: jj-zhang25(at)mails(dot)tsinghua(dot)edu(dot)cn, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #19644: byteaout, float8out and float4out are marked IMMUTABLE but depend on GUCs
Date: 2026-09-08 08:34:17
Message-ID: CAHGQGwEtYBEaDsJyHs-rw4AZZRjsPAtMpxPxKU7PsQyY=ZFOZw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Sat, Sep 5, 2026 at 2:27 AM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> It's been wrong for so long that I'm not that rushed to fix it in 19.
> We might find that there are consequences to be dealt with, so better
> to let the fix settle in master.

Sounds reasonable.

> > On further review, point_out, ISTM that lseg_out, path_out, box_out, poly_out,
> > circle_out, and line_out are marked IMMUTABLE but depend on extra_float_digits.
> > Similarly, pg_mcv_list_out is marked IMMUTABLE but depends on bytea_output.
> > Perhaps we should fix these at the same time...
>
> Agreed.

Attached patch marks those GUC-dependent type output functions as STABLE.

In addition to the functions I mentioned upthread, I found that
brin_minmax_multi_summary_out calls the summarized type's output
function, so its result can depend on the GUCs. The patch marks that
function STABLE as well.

Regards,

--
Fujii Masao

Attachment Content-Type Size
v1-0001-Mark-GUC-dependent-type-output-functions-as-STABL.patch application/octet-stream 6.7 KB

In response to

Browse pgsql-bugs by date

  From Date Subject
Previous Message Álvaro Herrera 2026-09-08 07:25:25 Re: REPACK (CONCURRENTLY) doesn't handle invalid indexes