mirror of
https://github.com/postgres/postgres.git
synced 2025-10-27 00:12:01 +03:00
Move hash_any prototype from access/hash.h to utils/hashutils.h
... as well as its implementation from backend/access/hash/hashfunc.c to backend/utils/hash/hashfn.c. access/hash is the place for the hash index AM, not really appropriate for generic facilities, which is what hash_any is; having things the old way meant that anything using hash_any had to include the AM's include file, pointlessly polluting its namespace with unrelated, unnecessary cruft. Also move the HTEqual strategy number to access/stratnum.h from access/hash.h. To avoid breaking third-party extension code, add an #include "utils/hashutils.h" to access/hash.h. (An easily removed line by committers who enjoy their asbestos suits to protect them from angry extension authors.) Discussion: https://postgr.es/m/201901251935.ser5e4h6djt2@alvherre.pgsql
This commit is contained in:
@@ -34,6 +34,13 @@ typedef uint16 StrategyNumber;
|
||||
|
||||
#define BTMaxStrategyNumber 5
|
||||
|
||||
/*
|
||||
* Strategy numbers for hash indexes. There's only one valid strategy for
|
||||
* hashing: equality.
|
||||
*/
|
||||
#define HTEqualStrategyNumber 1
|
||||
|
||||
#define HTMaxStrategyNumber 1
|
||||
|
||||
/*
|
||||
* Strategy numbers common to (some) GiST, SP-GiST and BRIN opclasses.
|
||||
|
||||
Reference in New Issue
Block a user