7a53b2f4c8
It is not reported for 1.0 language version because renaming to _ is not possible. It has weak warning severity So #KT-8813 Fixed So #KT-16875 Fixed
17 lines
445 B
Kotlin
Vendored
17 lines
445 B
Kotlin
Vendored
// !DIAGNOSTICS: -UNUSED_PARAMETER -UNUSED_ANONYMOUS_PARAMETER
|
|
// !CHECK_TYPE
|
|
|
|
// FILE: Clazz.java
|
|
public class Clazz<Psi> {
|
|
public java.util.Collection<Psi> foo() { return null; }
|
|
}
|
|
|
|
// FILE: main.kt
|
|
|
|
public fun <T, C : MutableCollection<in T>> Iterable<T>.filterTo(destination: C, predicate: (T) -> Boolean) {}
|
|
|
|
fun test(clazz: Clazz<out Any>) {
|
|
val result = java.util.ArrayList<Any>()
|
|
clazz.foo().filterTo(result) { x -> true }
|
|
}
|