Grigorii Yurkov
03/07/2021, 4:34 PMArray<Int>
and Array<in Int>
? In my opinion it should be Array<in Int>
. But kotlin compiler thinks it's Array<out Int?>
. I agree that Array<out Int?>
is supertype of both Array<Int>
and Array<in Int>
, but it's not the lowest. What do you think?ilya.gorbunov
03/09/2021, 5:04 AMArray<in Int>
, so in this case the type inference seems to be not inferring the most specific supertype.
I've opened https://youtrack.jetbrains.com/issue/KT-45362 to track this problem, feel free to vote or star it to follow the updates on it.