Repository navigation
@WillBecomeValue annotation #504
zhelenskiy
announced in
keep-discussions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
This is the discussion related to the
@WillBecomeValue annotation. The current full text of the proposal can be found here.It is proposed to add a
@WillBecomeValueannotation for classes that are value-like but can't yet be value classes (multiple fields, open, etc.). It makes the compiler warn on identity-sensitive usages (===,synchronized,identityHashCode), so users can fix their code before the class actually converts and those usages become errors. Analog of Java's@jdk.internal.ValueBased(JEP 390).All reactions