Retire MemoryContextResetAndDeleteChildren() macro. As of commit eaa5808e8e, MemoryContextResetAndDeleteChildren() is just a backwards compatibility macro for MemoryContextReset(). Now that some time has passed, this macro seems more likely to create confusion.
This commit removes the macro and replaces all remaining uses with calls to MemoryContextReset(). Any third-party code that use this macro will need to be adjusted to call MemoryContextReset() instead. Since the two have behaved the same way since v9.5, such adjustments won't produce any behavior changes for all currently-supported versions of PostgreSQL. Reviewed-by: Amul Sul, Tom Lane, Alvaro Herrera, Dagfinn Ilmari Mannsåker Discussion: https://postgr.es/m/20231113185950.GA1668018%40nathanxps13 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/6a72c42fd5af7ada49584694f543eb06dddb4a87 Modified Files -------------- src/backend/access/brin/brin.c | 4 ++-- src/backend/access/gin/ginscan.c | 2 +- src/backend/access/transam/xact.c | 4 ++-- src/backend/commands/analyze.c | 6 +++--- src/backend/executor/nodeRecursiveunion.c | 2 +- src/backend/executor/nodeSetOp.c | 2 +- src/backend/executor/nodeWindowAgg.c | 10 +++++----- src/backend/executor/spi.c | 4 ++-- src/backend/postmaster/autovacuum.c | 10 +++++----- src/backend/postmaster/bgwriter.c | 2 +- src/backend/postmaster/checkpointer.c | 2 +- src/backend/postmaster/walwriter.c | 2 +- src/backend/replication/logical/worker.c | 2 +- src/backend/statistics/extended_stats.c | 2 +- src/backend/tcop/postgres.c | 2 +- src/backend/utils/cache/evtcache.c | 4 ++-- src/backend/utils/error/elog.c | 2 +- src/include/utils/memutils.h | 3 --- 18 files changed, 31 insertions(+), 34 deletions(-)