[
https://issues.apache.org/jira/browse/LUCENE-7715?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15887663#comment-15887663
]
Adrien Grand commented on LUCENE-7715:
--------------------------------------
I haven't tried the patch, but I don't see how it deals with the initial state
that all sub spans have a start position of -1. In master currently,
nextStartPosition iterates over the pq until the start position of the top
element is greater than -1, but I don't see that logic in your patch. There is
a {{startDocument}} method but if I am not mistaken it is only called from
two-phase iteration, so if {{NearSpansUnordered}} are consumed directly, that
would work, but not if they are nested within other spans? (I'm not very
familiar with spans so I could easily miss something.)
> Simplify NearSpansUnordered
> ---------------------------
>
> Key: LUCENE-7715
> URL: https://issues.apache.org/jira/browse/LUCENE-7715
> Project: Lucene - Core
> Issue Type: Bug
> Components: core/search
> Affects Versions: master (7.0)
> Reporter: Paul Elschot
> Priority: Minor
> Attachments: LUCENE-7715.patch
>
>
> {code}
> git diff --stat master...
> .../spans/NearSpansUnordered.java | 211 ++++---------
> 1 file changed, 59 insertions(+), 152 deletions(-)
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]