[jira] [Commented] (LUCENE-4924) Make DocIdSetIterator.docID() return -1 when not positioned
[ https://issues.apache.org/jira/browse/LUCENE-4924?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13631697#comment-13631697 ] Adrien Grand commented on LUCENE-4924: -- I plan to commit soon and backport everything to 4.x but the changes entry and the DocIdSetIterator.docID() javadoc change. Make DocIdSetIterator.docID() return -1 when not positioned --- Key: LUCENE-4924 URL: https://issues.apache.org/jira/browse/LUCENE-4924 Project: Lucene - Core Issue Type: Improvement Reporter: Adrien Grand Assignee: Adrien Grand Priority: Minor Fix For: 5.0 Attachments: LUCENE-4924.patch, LUCENE-4924.patch, LUCENE-4924.patch Today DocIdSetIterator.docID() can either return -1 or NO_MORE_DOCS when the enum is not positioned. I would like to only allow it to return -1 so that we can have better assertions. (This proposal is for trunk only.) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (LUCENE-4924) Make DocIdSetIterator.docID() return -1 when not positioned
[ https://issues.apache.org/jira/browse/LUCENE-4924?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13631757#comment-13631757 ] Yonik Seeley commented on LUCENE-4924: -- +1, looks good! Make DocIdSetIterator.docID() return -1 when not positioned --- Key: LUCENE-4924 URL: https://issues.apache.org/jira/browse/LUCENE-4924 Project: Lucene - Core Issue Type: Improvement Reporter: Adrien Grand Assignee: Adrien Grand Priority: Minor Fix For: 5.0 Attachments: LUCENE-4924.patch, LUCENE-4924.patch, LUCENE-4924.patch Today DocIdSetIterator.docID() can either return -1 or NO_MORE_DOCS when the enum is not positioned. I would like to only allow it to return -1 so that we can have better assertions. (This proposal is for trunk only.) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (LUCENE-4924) Make DocIdSetIterator.docID() return -1 when not positioned
[ https://issues.apache.org/jira/browse/LUCENE-4924?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13627721#comment-13627721 ] Yonik Seeley commented on LUCENE-4924: -- Undefined can sometimes lead to more efficient implementations in certain circumstances. IIRC this was actually true of some iterators at some point in the past, but I don't know if it's still the case. Make DocIdSetIterator.docID() return -1 when not positioned --- Key: LUCENE-4924 URL: https://issues.apache.org/jira/browse/LUCENE-4924 Project: Lucene - Core Issue Type: Improvement Reporter: Adrien Grand Priority: Minor Fix For: 5.0 Today DocIdSetIterator.docID() can either return -1 or NO_MORE_DOCS when the enum is not positioned. I would like to only allow it to return -1 so that we can have better assertions. (This proposal is for trunk only.) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (LUCENE-4924) Make DocIdSetIterator.docID() return -1 when not positioned
[ https://issues.apache.org/jira/browse/LUCENE-4924?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13627732#comment-13627732 ] Robert Muir commented on LUCENE-4924: - undefined is no option at all: things rely upon this behavior (e.g. disjunctionsumscorer, i was just looking at that one last night). Make DocIdSetIterator.docID() return -1 when not positioned --- Key: LUCENE-4924 URL: https://issues.apache.org/jira/browse/LUCENE-4924 Project: Lucene - Core Issue Type: Improvement Reporter: Adrien Grand Priority: Minor Fix For: 5.0 Today DocIdSetIterator.docID() can either return -1 or NO_MORE_DOCS when the enum is not positioned. I would like to only allow it to return -1 so that we can have better assertions. (This proposal is for trunk only.) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org
[jira] [Commented] (LUCENE-4924) Make DocIdSetIterator.docID() return -1 when not positioned
[ https://issues.apache.org/jira/browse/LUCENE-4924?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=1362#comment-1362 ] Michael McCandless commented on LUCENE-4924: bq. I would like to only allow it to return -1 so that we can have better assertions. +1 Make DocIdSetIterator.docID() return -1 when not positioned --- Key: LUCENE-4924 URL: https://issues.apache.org/jira/browse/LUCENE-4924 Project: Lucene - Core Issue Type: Improvement Reporter: Adrien Grand Priority: Minor Fix For: 5.0 Today DocIdSetIterator.docID() can either return -1 or NO_MORE_DOCS when the enum is not positioned. I would like to only allow it to return -1 so that we can have better assertions. (This proposal is for trunk only.) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org