Hi is there a way to tell kotlin that all of the f...
# announcements
m
Hi is there a way to tell kotlin that all of the functions inside an object or companion object must be annotated with
@JvmStatic
? without need to annotating individual functions
s
it’s not mentioned in the docs https://kotlinlang.org/docs/reference/java-to-kotlin-interop.html#static-methods so probably not. I guess you’d want an annotation on the companion object that adds
@JvmStatic
to all of it’s methods. The problem is most likely that the semantics would get complicated once you realise that companion objects can extend other objects.
a
It's currently not possible, please vote for the feature request https://youtrack.jetbrains.com/issue/KT-14219
m
seems like it won't we added soon enough because issue been created 3 years ago and only 3 people voted for it