Use warn mode by default for jspecify nullability annotations in 1.6

^KT-48851 Fixed
This commit is contained in:
Victor Petukhov
2021-09-21 16:37:40 +03:00
parent 013139f18e
commit 70d70b9042
13 changed files with 131 additions and 6 deletions
+5 -2
View File
@@ -1,4 +1,7 @@
compiler/testData/cli/jvm/jspecifyUsage.kt:2:11: error: null can not be a value of a non-null type String
compiler/testData/cli/jvm/jspecifyUsage.kt:2:11: warning: type mismatch: inferred type is Nothing? but String was expected
a.foo(null)
^
COMPILATION_ERROR
compiler/testData/cli/jvm/jspecifyUsage.kt:3:5: warning: unsafe use of a nullable receiver of type String?
a.bar().hashCode()
^
OK
+5 -2
View File
@@ -1,4 +1,7 @@
compiler/testData/cli/jvm/jspecifyUsage.kt:2:11: error: null can not be a value of a non-null type String
compiler/testData/cli/jvm/jspecifyUsage.kt:2:11: warning: type mismatch: inferred type is Nothing? but String was expected
a.foo(null)
^
COMPILATION_ERROR
compiler/testData/cli/jvm/jspecifyUsage.kt:3:5: warning: unsafe use of a nullable receiver of type String?
a.bar().hashCode()
^
OK