An example of what would presumably happen if we adopted this sort of rule (I've not checked whether the patch as written does this, but it would logically follow) is that appending a float to an integer array would cause the whole array to be silently promoted to float, with attendant possible loss of precision for existing array elements.
it is based on select_common_type() - so it is use only available implicit casts.
Without patch:
postgres=# select pg_typeof(array_append('{1,2,3}'::int[], 1.2::float)); ERROR: function array_append(integer[], double precision) does not exist