On Fri, Jun 11, 2021 at 08:56:19PM -0400, Tom Lane wrote: > Bruce Momjian <br...@momjian.us> writes: > > OK, I came up with the attached patch. This is one of the few cases > > where the incompatibility is not clearly related to the feature, so I > > left the existing item alone and just created a new one with the same > > commit message in the incompatibilities section. > > I think phrasing this as though user-defined aggregates are the only > pain point is incorrect. For example, a custom operator based on > array_cat would have issues too. > > I suggest a treatment more like > > Some built-in array-related functions changed signature (Tom Lane) > > Certain functions were redefined to take anycompatiblearray instead > of anyarray. While this does not affect ordinary calls, it does > affect code that directly names these functions along with their > argument types; for example, custom aggregates and operators based > on these functions. The affected functions are [ blah, blah ]
OK, I used some of your ideas and tried for something more general; patch attached. -- Bruce Momjian <br...@momjian.us> https://momjian.us EDB https://enterprisedb.com If only the physical world exists, free will is an illusion.
diff --git a/doc/src/sgml/release-14.sgml b/doc/src/sgml/release-14.sgml index 058ba7cd4e..9211115690 100644 --- a/doc/src/sgml/release-14.sgml +++ b/doc/src/sgml/release-14.sgml @@ -291,6 +291,34 @@ Author: Tom Lane <t...@sss.pgh.pa.us> <listitem> <!-- Author: Tom Lane <t...@sss.pgh.pa.us> +2020-11-04 [9e38c2bb5] Declare assorted array functions using anycompatible not +--> + + <para> + User-defined objects that reference some built-in array functions + along with their argument types must be recreated (Tom Lane) + </para> + + <para> + Specifically, <link + linkend="functions-array"><function>array_append()</function></link>, + <function>array_prepend()</function>, + <function>array_cat()</function>, + <function>array_position()</function>, + <function>array_positions()</function>, + <function>array_remove()</function>, + <function>array_replace()</function>, or <link + linkend="functions-math"><function>width_bucket()</function></link> + used to take <type>anyarray</type> arguments but now take + <type>anycompatiblearray</type>. Therefore, user-defined objects + that reference the old array function signature must be dropped + before upgrading and recreated once the upgrade completes. + </para> + </listitem> + + <listitem> +<!-- +Author: Tom Lane <t...@sss.pgh.pa.us> 2020-09-17 [76f412ab3] Remove factorial operators, leaving only the factorial() -->