jpountz commented on PR #12638: URL: https://github.com/apache/lucene/pull/12638#issuecomment-1759681148
@yugushihuang Your explanation suggests that a `TermStates` could be created somewhere and then used in a different context. But this is not how it's expected to be used in general, the expectation is that the same caller owns both the creation and then the consumption of the `TermStates` object, so it knows exactly how it's been created. An example is `TermWeight`: it creates the `TermStates` object itself based on the `ScoreMode` so it knows whether the `TermStates` object has stats or not later on when it consumes it. -- 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. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org