Many guids in which try to explain differences between ? extend T
and ? super T
use as example method java.util.Collections#copy
public static <T> void copy(List<? super T> dest, List<? extends T> src) {
}
How this method should look in kotlin? If i try to copy and past this method in Kotlin class and convert to kotlin by IntelliJ Idea when this method look like
fun <T> copy(dest: List<in T?>?, src: List<T?>?) {}
But this code not compiled.