]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Add assertions for all the required index AM callbacks
authorMichael Paquier <michael@paquier.xyz>
Sun, 27 Jul 2025 08:48:47 +0000 (17:48 +0900)
committerMichael Paquier <michael@paquier.xyz>
Sun, 27 Jul 2025 08:48:47 +0000 (17:48 +0900)
commit6f22a82a401d267e4bf1fcbcff8d6adb24e14d58
treea982018c9a315d602bbc6186255ddca065ac3341
parentdb6461b1c9aae122b90bb52430f06efb306b371a
Add assertions for all the required index AM callbacks

Similar checks are done for the mandatory table AM callbacks.  A portion
of the index AM callbacks are optional and can be NULL; the rest is
mandatory and is documented as such in the documentation and in amapi.h.

These checks are useful to detect quickly if all the mandatory callbacks
are defined when implementing a new index access method, as the
assertions are run when loading the AM.

Author: Japin Li <japinli@hotmail.com>
Discussion: https://postgr.es/m/ME0P300MB0445795D31CEAB92C58B41FDB651A@ME0P300MB0445.AUSP300.PROD.OUTLOOK.COM
src/backend/access/index/amapi.c