[FIR] Add NO_THIS & INSTANCE_ACCESS_BEFORE_SUPER_CALL
This commit is contained in:
Vendored
+3
-3
@@ -10,13 +10,13 @@ class Foo {
|
||||
inner class Bar {
|
||||
fun good() {
|
||||
contract {
|
||||
returns() implies (this@Bar != null)
|
||||
returns() implies (<!UNRESOLVED_LABEL!>this@Bar<!> != null)
|
||||
}
|
||||
}
|
||||
|
||||
fun badOuter() {
|
||||
contract {
|
||||
returns() implies (this@Foo != null)
|
||||
returns() implies (<!UNRESOLVED_LABEL!>this@Foo<!> != null)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ class Foo {
|
||||
|
||||
fun A?.badWithReceiver() {
|
||||
contract {
|
||||
returns() implies (this@Bar != null)
|
||||
returns() implies (<!UNRESOLVED_LABEL!>this@Bar<!> != null)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
interface Inv
|
||||
class Impl : Inv
|
||||
|
||||
class Scope<InterfaceT, ImplementationT : InterfaceT>(private val implClass: <!UNRESOLVED_REFERENCE, UNRESOLVED_REFERENCE, UNRESOLVED_REFERENCE!>j.Class<ImplementationT><!>) {
|
||||
class Scope<InterfaceT, ImplementationT : InterfaceT>(private val implClass: <!UNRESOLVED_REFERENCE!>j.Class<ImplementationT><!>) {
|
||||
fun foo(c: Collection<InterfaceT>) {
|
||||
val hm = c.asSequence()
|
||||
.<!INAPPLICABLE_CANDIDATE!>filter<!>(<!UNRESOLVED_REFERENCE!>implClass::isInstance<!>)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
data class A(val x: <!UNRESOLVED_REFERENCE, UNRESOLVED_REFERENCE!>Set<CLassNotFound><!> = setOf()) {
|
||||
fun with(x: <!UNRESOLVED_REFERENCE, UNRESOLVED_REFERENCE!>Set<CLassNotFound>?<!> = null) {
|
||||
data class A(val x: <!UNRESOLVED_REFERENCE!>Set<CLassNotFound><!> = setOf()) {
|
||||
fun with(x: <!UNRESOLVED_REFERENCE!>Set<CLassNotFound>?<!> = null) {
|
||||
A(x ?: this.x)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user