Files
kotlin-fork/idea/testData/intentions/loopToCallChain/any/indexNeeded.kt.after2
T
2016-08-23 22:47:42 +03:00

9 lines
311 B
Plaintext
Vendored

// WITH_RUNTIME
// INTENTION_TEXT: "Replace with 'filterIndexed{}.any()'"
// INTENTION_TEXT_2: "Replace with 'asSequence().filterIndexed{}.any()'"
fun foo(list: List<String>) {
val <caret>found = list
.asSequence()
.filterIndexed { index, s -> s.length > index }
.any()
}