Files
kotlin-fork/compiler/testData/diagnostics/tests/resolve/inferenceInLinkedLambdas.kt
T
2015-07-10 15:05:07 +03:00

9 lines
212 B
Kotlin
Vendored

// !DIAGNOSTICS: -UNUSED_PARAMETER
// !CHECK_TYPE
fun <T, R> foo(first: () -> T, second: (T) -> R): R = throw Exception()
fun test() {
val r = foo( { 4 }, { "${it + 1}" } )
r checkType { _<String>() }
}