2ecba6ac39
This directive anyway does not make test run twice with OI, and with NI It only once run the test with specific settings (// LANGUAGE) and ignores irrelevant (OI or NI tags)
33 lines
845 B
Kotlin
Vendored
33 lines
845 B
Kotlin
Vendored
//!DIAGNOSTICS: -UNUSED_PARAMETER
|
|
|
|
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
|
fun <T> test1(t1: T, t2: @kotlin.internal.NoInfer T): T = t1
|
|
|
|
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
|
fun <T> @kotlin.internal.NoInfer T.test2(t1: T): T = t1
|
|
|
|
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
|
fun <T> test3(t1: @kotlin.internal.NoInfer T): T = t1
|
|
|
|
fun usage() {
|
|
test1(1, "312")
|
|
1.test2("")
|
|
test3("")
|
|
}
|
|
|
|
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
|
fun <T> List<T>.contains1(e: @kotlin.internal.NoInfer T): Boolean = true
|
|
|
|
fun test(i: Int?, a: Any, l: List<Int>) {
|
|
l.contains1(a)
|
|
l.contains1("")
|
|
l.contains1(i)
|
|
}
|
|
|
|
@Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
|
fun <T> assertEquals1(e1: T, e2: @kotlin.internal.NoInfer T): Boolean = true
|
|
|
|
fun test(s: String) {
|
|
assertEquals1(s, 11)
|
|
}
|