Is it intended behavior that `data class @JvmRecor...
# getting-started
j
Is it intended behavior that
data class @JvmRecord SomeClass(@JvmField val field: String)
generates bytecode for a class that is a record, but violates the record assuption of having a method named
field()
?
h
This is just how Java records work: there is a public method with the same field name. The jvmfield annotation has no effect.
j
It seems that if you try reflection to get that method you get a null, which lead to a bug for me (graalvm native compile)