[FIR] Implement NULL_FOR_NONNULL_TYPE diagnostics, fix tests
This commit is contained in:
Vendored
+2
-2
@@ -23,8 +23,8 @@ fun foo(k: KotlinClass) {
|
||||
|
||||
k.setSomething4("")
|
||||
k.something4 += ""
|
||||
k.setSomething4(<!ARGUMENT_TYPE_MISMATCH!>null<!>)
|
||||
k.something4 = null
|
||||
k.setSomething4(<!NULL_FOR_NONNULL_TYPE!>null<!>)
|
||||
k.something4 = <!NULL_FOR_NONNULL_TYPE!>null<!>
|
||||
|
||||
useString(k.getSomething5())
|
||||
useString(k.something5)
|
||||
|
||||
Vendored
-13
@@ -1,13 +0,0 @@
|
||||
// !WITH_NEW_INFERENCE
|
||||
// FILE: KotlinFile.kt
|
||||
fun foo(javaInterface: JavaInterface) {
|
||||
javaInterface.doIt(<!ARGUMENT_TYPE_MISMATCH!>null<!>) { }
|
||||
javaInterface.doIt("", <!ARGUMENT_TYPE_MISMATCH!>null<!>)
|
||||
}
|
||||
|
||||
// FILE: JavaInterface.java
|
||||
import org.jetbrains.annotations.*;
|
||||
|
||||
public interface JavaInterface {
|
||||
void doIt(@NotNull String s, @NotNull Runnable runnable);
|
||||
}
|
||||
Vendored
+1
@@ -1,3 +1,4 @@
|
||||
// FIR_IDENTICAL
|
||||
// !WITH_NEW_INFERENCE
|
||||
// FILE: KotlinFile.kt
|
||||
fun foo(javaInterface: JavaInterface) {
|
||||
|
||||
Reference in New Issue
Block a user