Files
kotlin-fork/idea/testData/inspectionsLocal/collections/convertCallChainIntoSequence/termination/groupByTo.kt
T
Toshiaki Kameyama 7e28cb1fe3 Call chain --> Sequence: take termination into account
Related to KT-15476
2018-08-08 11:02:47 +03:00

5 lines
164 B
Kotlin
Vendored

// WITH_RUNTIME
fun test(list: List<Int>) {
val groupByTo: MutableMap<Int, MutableList<Int>> = list.<caret>filter { it > 1 }.groupByTo(mutableMapOf()) { it }
}