-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LUCENE-10239: upgrade jflex (1.7.0 -> 1.8.2) #452
Conversation
Upgrade jflex. Change doesn't alter the behavior of any of the analyzers (unicode version or grammar refactorings), just the minimal to get new tooling working.
I thought to try to do a large refactoring here and quickly backed off, I think let's just upgrade to the latest jflex as a standalone change. The trickiest parts (and ones needing close review):
|
dev-tools/missing-doclet/src/main/java/org/apache/lucene/missingdoclet/MissingDoclet.java
Show resolved
Hide resolved
token: 'SuppressWarnings("FallThrough")', | ||
value: 'SuppressWarnings({"fallthrough","unused"})' | ||
) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the hack we have to do for now, see jflex-de/jflex#762 where a method is being discussed to customize the suppress warnings without find-replace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
dev-tools/missing-doclet/src/main/java/org/apache/lucene/missingdoclet/MissingDoclet.java
Show resolved
Hide resolved
For convenience of reviewing: here is the diff between default skeleton and "buffer-expansion-disabled" skeleton. It is kinda the only way to review it since we brought in all the upstream changes.
|
I tried to look up why this no-buffer-expansion is needed. I see LUCENE-8527 and some corner cases there... but why is it used here and there and not all across the board (some tokenizers use the default and others use the no-buffer version). |
@dweiss see https://issues.apache.org/jira/browse/LUCENE-5897 for more background on that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks Robert.
I like the strategy of upgrading the dependency first and then working on the Unicode upgrades later.
Upgrade jflex. Change doesn't alter the behavior of any of the analyzers (unicode version or grammar refactorings), just the minimal to get new tooling working.
Upgrade jflex.
Change doesn't alter the behavior of any of the analyzers (unicode version or grammar refactorings), just the minimal to get new tooling working.