Passing DataFlowInfo to local classes/objects

#KT-2835 In Progress
#KT-2225 In Progress
#KT-338 In Progress
This commit is contained in:
Andrey Breslav
2013-08-19 17:34:46 +04:00
parent c95f2b78c8
commit 63c284e200
15 changed files with 185 additions and 35 deletions
@@ -0,0 +1,15 @@
// KT-2225 Object expression delegation parameter should be checked with data flow info
trait A {
fun foo() : Int
}
class B : A {
override fun foo() = 10
}
fun foo(b: B?) : Int {
if (b == null) return 0
val o = object : A by b { //no info about b not null check
}
return o.foo()
}