git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@782625 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yonik Seeley 2009-06-08 13:52:12 +00:00
parent 734ee07107
commit 9382159d10
2 changed files with 2 additions and 2 deletions

View File

@ -122,7 +122,7 @@ public class BoostedQuery extends Query {
public float score() throws IOException {
float score = qWeight * scorer.score() * vals.floatVal(scorer.doc());
// current Lucene sorting priority queues can't handle NaN and -Infinity
// current Lucene sorting priority queues can't handle NaN (score!=score is true for NaN) and -Infinity
if (score != score || score==Float.NEGATIVE_INFINITY) return -Float.MAX_VALUE;
return score;
}

View File

@ -133,7 +133,7 @@ public class FunctionQuery extends Query {
public float score() throws IOException {
float score = qWeight * vals.floatVal(doc);
// current Lucene sorting priority queues can't handle NaN and -Infinity
// current Lucene sorting priority queues can't handle NaN (score!=score is true for NaN) and -Infinity
if (score != score || score==Float.NEGATIVE_INFINITY) return -Float.MAX_VALUE;
return score;
}