| From: | Fujii Masao <fujii(at)postgresql(dot)org> |
|---|---|
| To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
| Subject: | pgsql: Mark GUC-dependent type output functions as STABLE |
| Date: | 2026-10-20 06:07:56 |
| Message-ID: | E1xJ30u-00000002LnZ-2emL@gemulon.postgresql.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-committers |
Mark GUC-dependent type output functions as STABLE
byteaout and pg_mcv_list_out depend on bytea_output GUC, while
float4out, float8out, and the geometric type output functions depend
on extra_float_digits GUC. The BRIN minmax-multi summary output
function also calls the summarized type's output function, so its result
can depend on the type's output settings.
Mark these functions STABLE instead of IMMUTABLE to reflect their
dependence on session settings. This prevents them from being used in
expressions that require immutability, such as expression indexes,
generated columns, and partition keys.
Do not backpatch, since this changes catalog entries and can break
existing schemas that rely on these output functions being immutable.
Bump catalog version.
Reported-by: 放空 <jj-zhang25(at)mails(dot)tsinghua(dot)edu(dot)cn>
Author: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Reviewed-by: Peter Eisentraut <peter(at)eisentraut(dot)org>
Discussion: https://postgr.es/m/19644-d6db3fb5e5ad92f4@postgresql.org
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/e75fcc9867fdfe295957ad5c9a98cbe2e1b4c5c3
Modified Files
--------------
src/include/catalog/catversion.h | 2 +-
src/include/catalog/pg_proc.dat | 46 ++++++++++++++++++++--------------------
2 files changed, 24 insertions(+), 24 deletions(-)
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Lane | 2026-10-20 16:56:24 | pgsql: Fix to_char() for number formats ending in a decimal point. |
| Previous Message | Noah Misch | 2026-10-20 02:36:28 | pgsql: Add Dockerfile for github.com/anthropics/oss-scanner. |