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: 放空 <[email protected]>
Author: Fujii Masao <[email protected]>
Reviewed-by: Peter Eisentraut <[email protected]>
Discussion: https://postgr.es/m/[email protected]

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(-)

Reply via email to