Remove function-wide hash set from effectiveJavaModifiers - #3122
Merged
Conversation
jaschdoc
force-pushed
the
refactor-effective-java-modifiers
branch
5 times, most recently
from
August 7, 2026 09:36
9c21d23 to
055bd7b
Compare
jaschdoc
force-pushed
the
refactor-effective-java-modifiers
branch
from
August 7, 2026 12:57
b28c758 to
03f0ac3
Compare
jaschdoc
marked this pull request as ready for review
August 17, 2026 10:28
jaschdoc
force-pushed
the
refactor-effective-java-modifiers
branch
from
August 17, 2026 10:28
03f0ac3 to
7c70e3f
Compare
jaschdoc
marked this pull request as draft
August 17, 2026 11:04
jaschdoc
marked this pull request as ready for review
August 17, 2026 11:08
jaschdoc
marked this pull request as draft
August 17, 2026 11:10
This refactoring makes each branch of the when-expression mutually exclusive instead of mutating a shared hash map. This is done to make it easier to support upcoming backing field requirements.
For Kotlin sources, the JvmStatic annotation was not resolved if it were (type-) aliased. This commit ensures it is always resolved.
jaschdoc
force-pushed
the
refactor-effective-java-modifiers
branch
from
August 17, 2026 13:08
f1ba010 to
362ac6b
Compare
jaschdoc
marked this pull request as ready for review
August 17, 2026 13:13
troelsbjerre
approved these changes
Aug 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This refactoring makes each branch of the when-expression mutually exclusive instead of mutating a shared hash map. This is done to make it easier to support upcoming backing field requirements. I might be a little slower due to joining immutable sets, but it makes it easier to make it correct. However, it's not clear if this is on a hot path so the correctness is preferred. I know this is a somewhat major change to the function internals, so feel free to request changes or reject the PR.
Related to #3110
Related to #2969
Related to #2873
Depends on #3126
Depends on #3130
Closes #3124