Files
kotlin/compiler/testData/diagnostics/tests/functionLiterals/functionLIteralInBlockInIf.kt
2017-11-29 02:53:49 +03:00

11 lines
179 B
Kotlin
Vendored

// !WITH_NEW_INFERENCE
// !CHECK_TYPE
fun test() {
val a = if (true) {
val x = 1
({ x })
} else {
{ 2 }
}
a checkType { _<() -> Int>() }
}