From 56b3f8b1fcbcac5177ced2c22ce7eaa770f6d4dd Mon Sep 17 00:00:00 2001 From: Adrien Grand Date: Tue, 16 Dec 2014 18:46:25 +0000 Subject: [PATCH] LUCENE-6116: Simplify RoaringDocIdSet.Iterator constructor. git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1646041 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/java/org/apache/lucene/util/RoaringDocIdSet.java | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/lucene/core/src/java/org/apache/lucene/util/RoaringDocIdSet.java b/lucene/core/src/java/org/apache/lucene/util/RoaringDocIdSet.java index 4ee409b7706..7d1e877474a 100644 --- a/lucene/core/src/java/org/apache/lucene/util/RoaringDocIdSet.java +++ b/lucene/core/src/java/org/apache/lucene/util/RoaringDocIdSet.java @@ -268,11 +268,8 @@ public class RoaringDocIdSet extends DocIdSet { Iterator() throws IOException { doc = -1; - block = 0; - while (docIdSets[block] == null) { - block += 1; - } - sub = docIdSets[block].iterator(); + block = -1; + sub = DocIdSetIterator.empty(); } @Override