Fix KT-10805 for 'when'.
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
val <!IMPLICIT_NOTHING_PROPERTY_TYPE!>test1<!> = when {
|
||||
true -> { <!TYPE_MISMATCH!>{ true }<!> }
|
||||
else -> TODO()
|
||||
}
|
||||
|
||||
val test1a: () -> Boolean = when {
|
||||
true -> { { true } }
|
||||
else -> TODO()
|
||||
}
|
||||
|
||||
val <!IMPLICIT_NOTHING_PROPERTY_TYPE!>test2<!> = when {
|
||||
true -> { <!TYPE_MISMATCH!>{ true }<!> }
|
||||
else -> when {
|
||||
true -> { <!TYPE_MISMATCH!>{ true }<!> }
|
||||
else -> TODO()
|
||||
}
|
||||
}
|
||||
|
||||
val test2a: () -> Boolean = when {
|
||||
true -> { { true } }
|
||||
else -> when {
|
||||
true -> { <!TYPE_MISMATCH!>{ true }<!> } // TODO
|
||||
else -> TODO()
|
||||
}
|
||||
}
|
||||
|
||||
val <!IMPLICIT_NOTHING_PROPERTY_TYPE!>test3<!> = when {
|
||||
true -> { <!TYPE_MISMATCH!>{ true }<!> }
|
||||
true -> { <!TYPE_MISMATCH!>{ true }<!> }
|
||||
else -> TODO()
|
||||
}
|
||||
|
||||
val test3a: () -> Boolean = when {
|
||||
true -> { { true } }
|
||||
true -> { { true } }
|
||||
else -> TODO()
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
package
|
||||
|
||||
public val test1: kotlin.Nothing
|
||||
public val test1a: () -> kotlin.Boolean
|
||||
public val test2: kotlin.Nothing
|
||||
public val test2a: () -> kotlin.Boolean
|
||||
public val test3: kotlin.Nothing
|
||||
public val test3a: () -> kotlin.Boolean
|
||||
Reference in New Issue
Block a user