dsmiley commented on a change in pull request #1037: LUCENE-9062: QueryVisitor.consumeTermsMatching URL: https://github.com/apache/lucene-solr/pull/1037#discussion_r350479038
########## File path: lucene/highlighter/src/java/org/apache/lucene/search/uhighlight/FieldOffsetStrategy.java ########## @@ -192,7 +193,7 @@ protected void createOffsetsEnumsForAutomata(Terms termsIndex, int doc, List<Off } for (int i = 0; i < automata.length; i++) { - CharacterRunAutomaton automaton = automata[i]; + CharArrayMatcher automaton = automata[i]; Review comment: Look further below where we call automata.toString(). While this still works because the implementing class of the CharArrayMatcher interface happens to be a subclass implemented by one of the anonymous classes inside MultiTermHighlighting, this is now more awkward. It was already awkward, granted. It's enough for me if you add a comment, and perhaps also comment on UHComponents.getAutomata to mention the toString contract. ---------------------------------------------------------------- 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