summaryrefslogtreecommitdiff
path: root/src/backend/access/gist/gistsplit.c
diff options
context:
space:
mode:
authorMichael Paquier2021-09-08 00:44:04 +0000
committerMichael Paquier2021-09-08 00:44:04 +0000
commitfd0625c7a9c679c0c1e896014b8f49a489c3a245 (patch)
treecacddafcd64a4f00d87f6551b29937f9e5ced415 /src/backend/access/gist/gistsplit.c
parentd6c916f020e291b45563d4e76a649e9364cb6f2d (diff)
Clean up some code using "(expr) ? true : false"
All the code paths simplified here were already using a boolean or used an expression that led to zero or one, making the extra bits unnecessary. Author: Justin Pryzby Reviewed-by: Tom Lane, Michael Paquier, Peter Smith Discussion: https://postgr.es/m/[email protected]
Diffstat (limited to 'src/backend/access/gist/gistsplit.c')
-rw-r--r--src/backend/access/gist/gistsplit.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/access/gist/gistsplit.c b/src/backend/access/gist/gistsplit.c
index 526ed1218e..853ebc387b 100644
--- a/src/backend/access/gist/gistsplit.c
+++ b/src/backend/access/gist/gistsplit.c
@@ -303,9 +303,9 @@ supportSecondarySplit(Relation r, GISTSTATE *giststate, int attno,
penalty2 = gistpenalty(giststate, attno, entry1, false, &entrySR, false);
if (penalty1 < penalty2)
- leaveOnLeft = (sv->spl_ldatum_exists) ? true : false;
+ leaveOnLeft = sv->spl_ldatum_exists;
else
- leaveOnLeft = (sv->spl_rdatum_exists) ? true : false;
+ leaveOnLeft = sv->spl_rdatum_exists;
}
if (leaveOnLeft == false)