Add quick-fix "Replace with safe call & elvis" #KT-17815 Fixed
This commit is contained in:
committed by
Mikhail Glukhikh
parent
c2707bb81b
commit
af53a0ecd5
@@ -0,0 +1,9 @@
|
||||
// "Replace scope function with safe (?.) call" "true"
|
||||
// WITH_RUNTIME
|
||||
var i = 0
|
||||
|
||||
fun foo(a: String?) {
|
||||
i = a.run {
|
||||
length<caret>
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
// "Replace scope function with safe (?.) call" "true"
|
||||
// WITH_RUNTIME
|
||||
var i = 0
|
||||
|
||||
fun foo(a: String?) {
|
||||
i = a?.run {
|
||||
length
|
||||
} ?: <caret>
|
||||
}
|
||||
Reference in New Issue
Block a user