do not need to check stand-alone class object for class,
when it's on the left hand side of dot it is analyzed in 'getIdForImplicitReceiver' (test added)
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
open class T {
|
||||
val x : Int? = null
|
||||
}
|
||||
|
||||
class A {
|
||||
class object: T() {
|
||||
}
|
||||
}
|
||||
|
||||
class B {
|
||||
class object: T() {
|
||||
}
|
||||
}
|
||||
|
||||
fun test() {
|
||||
if (A.x != null) {
|
||||
useInt(A.x)
|
||||
useInt(<!TYPE_MISMATCH!>B.x<!>)
|
||||
}
|
||||
}
|
||||
|
||||
fun useInt(i: Int) = i
|
||||
Reference in New Issue
Block a user