gsmiller commented on code in PR #1021: URL: https://github.com/apache/lucene/pull/1021#discussion_r922620035
########## lucene/core/src/java/org/apache/lucene/index/SortedSetDocValuesWriter.java: ########## @@ -391,11 +386,7 @@ public boolean advanceExact(int target) throws IOException { @Override public long nextOrd() { - if (limit == ordUpto) { - return NO_MORE_ORDS; - } else { - return ords.ords.get(ordUpto++); - } + return ords.ords.get(ordUpto++); Review Comment: @LuXugang yeah, that's exactly right. The caller is now responsible for using `docValueCount()` to determine how many values the positioned doc has, and shouldn't call `nextOrd()` more than that many times. You're right that we could remove `limit` from `SortingSortedNumericDocValues` as well. I just missed it. Would you like to follow up with a change to remove it? I can get to it next week too. Thanks for pointing this out! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org