r/java • u/TheMrMilchmann • Jun 05 '26
Introducing opt-in requirements for Java APIs
https://osmerion.github.io/OptIn/blog/welcome
46
Upvotes
r/java • u/TheMrMilchmann • Jun 05 '26
View all comments
Show parent comment
12
u/repeating_bears Jun 05 '26
You need something to say what you're opting into.
Declaring the annotation is the library author's way to declare the what.
Without that, you only have the granularity of the library saying "it's experimental" and the user saying "I accept everything experimental from every library".