coerce condition value to Type.BOOLEAN (KT-2147)

This commit is contained in:
Dmitry Jemerov
2012-05-31 13:59:42 +02:00
parent 33f0a3cee0
commit b03966e8d0
3 changed files with 19 additions and 9 deletions
@@ -0,0 +1,9 @@
class Foo {
fun isOk() = true
}
fun box(): String {
val foo: Foo? = Foo()
if (foo?.isOk()!!) return "OK"
return "fail"
}