mikemccand commented on a change in pull request #895: LUCENE-8985: SynonymGraphFilter cannot handle input stream with tokens filtered. URL: https://github.com/apache/lucene-solr/pull/895#discussion_r356636844
########## File path: lucene/analysis/common/src/java/org/apache/lucene/analysis/synonym/SynonymGraphFilter.java ########## @@ -98,67 +100,44 @@ private final ByteArrayDataInput bytesReader = new ByteArrayDataInput(); private final BytesRef scratchBytes = new BytesRef(); private final CharsRefBuilder scratchChars = new CharsRefBuilder(); - private final LinkedList<BufferedOutputToken> outputBuffer = new LinkedList<>(); - - private int nextNodeOut; - private int lastNodeOut; - private int maxLookaheadUsed; + private final Queue<BufferedToken> tokenQueue; // For testing: private int captureCount; - private boolean liveToken; - - // Start/end offset of the current match: - private int matchStartOffset; - private int matchEndOffset; - - // True once the input TokenStream is exhausted: - private boolean finished; - private int lookaheadNextRead; - private int lookaheadNextWrite; + static class BufferedToken{ Review comment: Space before `{`? ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org