Files
kotlin-fork/compiler/testData/codegen/box/inference/builderInference/callableReferencesProperCompletion.kt
T
Denis.Zharkov d0a0739d10 FIR: Mute builder-inference related tests
They started failing once we began reporting diagnostics from completion

^KT-46421 Relates
2021-05-20 17:24:16 +03:00

74 lines
1.2 KiB
Kotlin
Vendored

// DONT_TARGET_EXACT_BACKEND: WASM
// WITH_RUNTIME
// IGNORE_BACKEND_FIR: JVM_IR
fun nonGenericId(x: Any?) = x
fun <T> id(x: T) = x
fun test1(): Sequence<String> = sequence {
yield("")
this::class
}
fun <T> sequence2(block: suspend SequenceScope<T>.() -> Unit): Sequence<T> = Sequence { iterator(block) }
fun foo() {
sequence2<String> {
id(this::class)
}
}
fun test2(): Sequence<String> = sequence {
yield("")
id(this::class)
}
fun test3(): Sequence<String> = sequence {
yield("")
nonGenericId(this::class)
}
fun test4(): Sequence<String> = sequence {
yield("")
this::`yield`
}
fun test5(): Sequence<String> = sequence {
yield("")
id(this::`yield`)
}
fun test6(): Sequence<String> = sequence {
yield("")
nonGenericId(this::`yield`)
}
fun test7(): Sequence<String> = sequence {
yield("")
::`yield`
}
fun test8(): Sequence<String> = sequence {
yield("")
id(::`yield`)
}
fun test9(): Sequence<String> = sequence {
yield("")
nonGenericId(::`yield`)
}
fun box(): String {
test1()
test2()
test3()
test4()
test5()
test6()
test7()
test8()
test9()
return "OK"
}