Files
kotlin/idea/testData/diagnosticMessage/functionPlaceholder.kt
Denis Zharkov 73799e2c3c Replace deprecated lambda syntax in testData
It's done with similar constructions where possible trying to preserve
intended behavior.
Some usages are removed because they test exactly the feature that
we are going to drop soon.
2015-09-25 08:29:25 +03:00

11 lines
202 B
Kotlin
Vendored

// !DIAGNOSTICS_NUMBER: 3
// !DIAGNOSTICS: TYPE_INFERENCE_PARAMETER_CONSTRAINT_ERROR
class A<T, R>
fun <T, R> foo(a: A<T, R>) = a
fun test() {
foo { it }
foo { x -> x}
foo { x: Int -> x}
}