From ae4472c619341ff0517254d395d74796277622e6 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Thu, 27 Dec 2018 10:07:46 +0100 Subject: Remove obsolete IndexIs* macros Remove IndexIsValid(), IndexIsReady(), IndexIsLive() in favor of accessing the index structure directly. These macros haven't been used consistently, and the original reason of maintaining source compatibility with PostgreSQL 9.2 is gone. Discussion: https://www.postgresql.org/message-id/flat/d419147c-09d4-6196-5d9d-0234b230880a%402ndquadrant.com --- src/backend/optimizer/util/plancat.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/backend/optimizer/util/plancat.c') diff --git a/src/backend/optimizer/util/plancat.c b/src/backend/optimizer/util/plancat.c index a570ac0aabe..5790b62369c 100644 --- a/src/backend/optimizer/util/plancat.c +++ b/src/backend/optimizer/util/plancat.c @@ -201,9 +201,9 @@ get_relation_info(PlannerInfo *root, Oid relationObjectId, bool inhparent, * queries. Note that this is OK because the data structure we * are constructing is only used by the planner --- the executor * still needs to insert into "invalid" indexes, if they're marked - * IndexIsReady. + * indisready. */ - if (!IndexIsValid(index)) + if (!index->indisvalid) { index_close(indexRelation, NoLock); continue; @@ -696,7 +696,7 @@ infer_arbiter_indexes(PlannerInfo *root) idxRel = index_open(indexoid, RowExclusiveLock); idxForm = idxRel->rd_index; - if (!IndexIsValid(idxForm)) + if (!idxForm->indisvalid) goto next; /* -- cgit v1.2.3