From 844ffc433f3cdd6a076c61a09bef85f736fa7a6b Mon Sep 17 00:00:00 2001 From: Michael McCandless Date: Tue, 7 Aug 2012 12:36:08 +0000 Subject: [PATCH] LUCENE-3892: add nocommit git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/branches/pforcodec_3892@1370207 13f79535-47bb-0310-9956-ffa450edef68 --- .../lucene/codecs/block/BlockPostingsReader.java | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/lucene/core/src/java/org/apache/lucene/codecs/block/BlockPostingsReader.java b/lucene/core/src/java/org/apache/lucene/codecs/block/BlockPostingsReader.java index bf65f91f08d..577a199b120 100644 --- a/lucene/core/src/java/org/apache/lucene/codecs/block/BlockPostingsReader.java +++ b/lucene/core/src/java/org/apache/lucene/codecs/block/BlockPostingsReader.java @@ -530,9 +530,13 @@ public final class BlockPostingsReader extends PostingsReaderBase { if (docUpto == docFreq) { return doc = NO_MORE_DOCS; } + + // nocommit: in theory we should not hit this? ie + // skipper should already have moved us to the block + // containing the doc? yet assert false trips ... i + // think because if you advance w/o having done a + // nextDoc yet()... can we assert/remove this? if (docBufferUpto == blockSize) { - // nocommit hmm skip freq? but: we don't ever - // scan over more than one block? refillDocs(); } accum += docDeltaBuffer[docBufferUpto]; @@ -842,6 +846,11 @@ public final class BlockPostingsReader extends PostingsReaderBase { if (docUpto == docFreq) { return doc = NO_MORE_DOCS; } + // nocommit: in theory we should not hit this? ie + // skipper should already have moved us to the block + // containing the doc? yet assert false trips ... i + // think because if you advance w/o having done a + // nextDoc yet()... can we assert/remove this? if (docBufferUpto == blockSize) { // nocommit hmm skip freq? but: we don't ever // scan over more than one block?