Hi hackers,
We have array_ref() and array_set() which are merely wrappers around
array_get_element() and array_set_element(). The wrappers take an
ArrayType * argument while array_{get|set}_element() take a Datum as
argument; like most of the other array functions.
array_ref() and array_set() are relicts from the following commit from 2015:
commit e983c4d1aa42d613542cf222e222b034918374b1
Author: Tom Lane <[email protected]>
Date: Mon Feb 16 12:23:58 2015 -0500
...
However, there's a fair amount of code using array_ref and array_set
with arrays that *are* known to be ArrayType structures, and there might
be more such places in third-party code.
This has changed over the years. On master there are only 5 calls to
array_ref() and 5 calls to array_set() left. Are there any objections
against cleaning up the code by removing array_ref() and array_set()?
--
David Geier