Java superclass and subclass generics in Kotlin
I'm looking for documentation or specifications about Java generics in Kotlin.
I'm curious about the behavior that is different between the superclass and the subclass.
For example, here is the following Java code.
// A.java
public class A {
public T value;
public A(T value) {
this.value = value;
}
}
// B.java
public class B extends A {
public B(T value) {
super(value);
}
}
Use the above Java code from Kotlin.
fun main() {
val a = A("a")
val b =...