[
https://issues.apache.org/jira/browse/LUCENE-1919?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12756909#action_12756909
]
Robert Muir commented on LUCENE-1919:
-------------------------------------
{quote}
edit: collision w/ robert.
Still wonder if it's safe to get rid of that second clone()... the combinations
are mind-bending.
{quote}
yonik, hmm i think the second clone() is a hint there remains another problem
if you look at my patch, it only fixes the case where you have a tokenstream
supporting incrementToken(), and you use both next() and next(Token) apis.
what if the tokenstream only supports next(reusableTS) ?
if you call next(token) then next(), i think in that case you will have the
same problem.
this still won't introduce any extra cloning, just fix the logic so it doesnt
overwrite the tokenWrapper, and returns a "full private copy" like the javadocs
say.
(i'll add another test and upload a new patch)
> Analysis back compat break
> --------------------------
>
> Key: LUCENE-1919
> URL: https://issues.apache.org/jira/browse/LUCENE-1919
> Project: Lucene - Java
> Issue Type: Bug
> Reporter: Yonik Seeley
> Fix For: 2.9
>
> Attachments: LUCENE-1919.patch, LUCENE-1919.patch, LUCENE-1919.patch
>
>
> Old and new style token streams don't mix well.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]