You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by jp...@apache.org on 2022/07/29 19:39:06 UTC
[lucene] branch main updated: LUCENE-10633: Fix handling of missing values in reverse sorts.
This is an automated email from the ASF dual-hosted git repository.
jpountz pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/lucene.git
The following commit(s) were added to refs/heads/main by this push:
new 7c9d3cd6ff6 LUCENE-10633: Fix handling of missing values in reverse sorts.
7c9d3cd6ff6 is described below
commit 7c9d3cd6ff6c6af153ee756a983dc323133f33c7
Author: Adrien Grand <jp...@gmail.com>
AuthorDate: Fri Jul 29 21:35:51 2022 +0200
LUCENE-10633: Fix handling of missing values in reverse sorts.
---
.../org/apache/lucene/search/comparators/TermOrdValComparator.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lucene/core/src/java/org/apache/lucene/search/comparators/TermOrdValComparator.java b/lucene/core/src/java/org/apache/lucene/search/comparators/TermOrdValComparator.java
index 36e64f6df89..cff3f846162 100644
--- a/lucene/core/src/java/org/apache/lucene/search/comparators/TermOrdValComparator.java
+++ b/lucene/core/src/java/org/apache/lucene/search/comparators/TermOrdValComparator.java
@@ -403,7 +403,7 @@ public class TermOrdValComparator extends FieldComparator<BytesRef> {
minOrd = -1;
}
- if (bottomOrd == Integer.MAX_VALUE) {
+ if (bottomOrd == missingOrd) {
// The queue still contains missing values.
if (singleSort) {
// If there is no tie breaker, we can start ignoring missing values from now on.
@@ -421,7 +421,7 @@ public class TermOrdValComparator extends FieldComparator<BytesRef> {
} else {
- if (bottomOrd == -1) {
+ if (bottomOrd == missingOrd) {
// The queue still contains missing values.
if (singleSort) {
// If there is no tie breaker, we can start ignoring missing values from now on.