KT-11104 extra : "wrap with safe let call" is now applicable for argument type mismatches

This commit is contained in:
Mikhail Glukhikh
2016-06-06 16:43:59 +03:00
committed by Mikhail Glukhikh
parent 47c1106d5d
commit 3c49b5f342
5 changed files with 46 additions and 4 deletions
@@ -0,0 +1,8 @@
// "Wrap with '?.let { ... }' call" "true"
// WITH_RUNTIME
fun foo(x: String?) {
bar(<caret>x)
}
fun bar(s: String) = s.hashCode()
@@ -0,0 +1,8 @@
// "Wrap with '?.let { ... }' call" "true"
// WITH_RUNTIME
fun foo(x: String?) {
x?.let { bar(it) }
}
fun bar(s: String) = s.hashCode()