Fix nullability quick-fixes with implicit receiver #KT-17726 Fixed

This commit is contained in:
Dmitry Neverov
2017-05-21 07:07:43 +02:00
committed by Mikhail Glukhikh
parent 9d2ae54d2c
commit 46aaee5d05
44 changed files with 479 additions and 23 deletions
+5
View File
@@ -0,0 +1,5 @@
// "Add non-null asserted (!!) call" "true"
fun String?.foo() {
<caret>length
}
@@ -0,0 +1,5 @@
// "Add non-null asserted (!!) call" "true"
fun String?.foo() {
this!!.length
}
@@ -0,0 +1,5 @@
// "Add non-null asserted (!!) call" "true"
// WITH_RUNTIME
fun String?.foo() {
<caret>toLowerCase()
}
@@ -0,0 +1,5 @@
// "Add non-null asserted (!!) call" "true"
// WITH_RUNTIME
fun String?.foo() {
this!!.toLowerCase()
}
+5
View File
@@ -0,0 +1,5 @@
// "Add non-null asserted (!!) call" "true"
fun foo(a: String?) {
a<caret>.length
}
@@ -0,0 +1,5 @@
// "Add non-null asserted (!!) call" "true"
fun foo(a: String?) {
a!!.length
}
+6
View File
@@ -0,0 +1,6 @@
// "Add non-null asserted (!!) call" "true"
// WITH_RUNTIME
fun foo(a: String?) {
a<caret>.toLowerCase()
}
@@ -0,0 +1,6 @@
// "Add non-null asserted (!!) call" "true"
// WITH_RUNTIME
fun foo(a: String?) {
a!!.toLowerCase()
}