1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-13 07:41:39 +03:00

Rename gist stratnum support function

Commit 7406ab623f added a gist support function that we internally
refer to by the symbol GIST_STRATNUM_PROC.  This translated from
"well-known" strategy numbers to opfamily-specific strategy numbers.
However, we later (commit 630f9a43ce) changed this to fit into
index-AM-level compare type mapping, so this function actually now
maps from compare type to opfamily-specific strategy numbers.  So this
name is no longer fitting.

Moreover, the index AM level also supports the opposite, a function to
map from strategy number to compare type.  This is currently not
supported in gist, but one might wonder what this function is supposed
to be called when it is added.

This patch changes the naming of the gist-level functionality to be
more in line with the index-AM-level functionality.  This makes sense
because these are essentially the same thing on different levels.
This also changes the names of the externally visible functions that
are provided for use as such a support function.

Reviewed-by: Paul A Jungwirth <pj@illuminatedcomputing.com>
Discussion: https://www.postgresql.org/message-id/37ebb1d9-9036-485f-a215-e55435689917%40eisentraut.org
This commit is contained in:
Peter Eisentraut
2025-06-02 08:33:04 +02:00
parent 5231ed8262
commit 32edf732e8
14 changed files with 92 additions and 81 deletions

View File

@ -1,3 +1,3 @@
-- test stratnum support func
SELECT gist_stratnum_btree(7);
SELECT gist_stratnum_btree(3);
-- test stratnum translation support func
SELECT gist_translate_cmptype_btree(7);
SELECT gist_translate_cmptype_btree(3);