Keep track of second receiver type in CallReceiver

#KT-17725 Fixed Target versions 1.1.5
This commit is contained in:
Dmitry Petrov
2017-07-21 10:37:20 +03:00
parent 3f34a97880
commit d0c8af5621
6 changed files with 49 additions and 5 deletions
+10
View File
@@ -0,0 +1,10 @@
class Bob {
fun Bob.bar() = "OK"
}
fun Any.foo() = when(this) {
is Bob -> bar()
else -> throw AssertionError()
}
fun box(): String = Bob().foo()