Files
Pavel Kirpichenkov 8c52bb4212 Add frontend checks for missing dependency supertypes
Call checker and declaration checker are used in order to preserve backward compatibility.
Attempt to use classifier usage checker was not good enouth,
since not all errors found with it would actually be reported before.
For example types and constructor calls don't cause supertypes to resolve,
so missing supertypes would not lead to errors in case they are the only use of class name.

Updated tests failing due to missing Java dependencies in superclasses.
2019-11-18 12:06:41 +03:00

10 lines
509 B
Kotlin
Vendored

import test.*
import test.SubClass.InnerStatic as ClassInnerStatic // No error - does not force supertype resolution for SubClass
import test.SubObject.InnerStatic // TODO report error - imports from object force resolution of its supertypes
fun test() {
SubClass().Inner() // Error - dispatch receiver misses supertype
SubClass.InnerStatic() // No error - does not force supertype resolution for SubClass
SubObject.InnerStatic() // TODO report error - for objects supertypes are resolved here
}