FIR checker: report SUPERTYPE_NOT_INITIALIZED

Combined this and the checker of
SUPERTYPE_INITIALIZED_WITHOUT_PRIMARY_CONSTRUCTOR together.

Also fixed SUPERTYPE_INITIALIZED_WITHOUT_PRIMARY_CONSTRUCTOR incorrectly
repoted as warning instead of error.
This commit is contained in:
Tianyu Geng
2021-03-09 15:25:05 -08:00
committed by Dmitriy Novozhilov
parent 6134c00698
commit 56bec6997c
30 changed files with 256 additions and 107 deletions
@@ -28,7 +28,7 @@ private class C {
}
}
class D : A {
class D : <!SUPERTYPE_NOT_INITIALIZED!>A<!> {
class Test1 : A.AProtectedI {
}
@@ -42,7 +42,7 @@ class Test2 : A.APublicI, <!UNRESOLVED_REFERENCE{LT}!><!UNRESOLVED_REFERENCE{PSI
}
class Test3 : C.CPublicI, <!EXPOSED_SUPER_CLASS!>C<!> {
class Test3 : C.CPublicI, <!EXPOSED_SUPER_CLASS, SUPERTYPE_NOT_INITIALIZED!>C<!> {
}
@@ -54,7 +54,7 @@ class Test5 : C.CPublicI, <!UNRESOLVED_REFERENCE{LT}!><!UNRESOLVED_REFERENCE{PSI
}
class Test6 : E, <!EXPOSED_SUPER_CLASS!>C.CPublic<!> {
class Test6 : E, <!EXPOSED_SUPER_CLASS, SUPERTYPE_NOT_INITIALIZED!>C.CPublic<!> {
}
@@ -23,7 +23,7 @@ internal class Test4<T: B>
// valid, B is internal
private class Test5<T: B>
public class Container : C {
public class Container : <!SUPERTYPE_NOT_INITIALIZED!>C<!> {
// valid, D is protected in C
protected class Test6<T: C.D>