Files
Alexey Belkov c4884de818 [kotlin] SuspiciousCollectionReassignmentInspection: fix offline report test
GitOrigin-RevId: ff4c10de64596259c1bdb0d4bdd124612aa63f99
2022-06-27 10:31:22 +00:00

8 lines
280 B
Kotlin

// PROBLEM: '+=' on a read-only list creates a new list under the hood
// FIX: Change type to mutable
// WITH_STDLIB
fun test() {
var list = listOf(1)
list <selection>+=<caret></selection> 2
}
// OFFLINE_REPORT: "'+=' on a read-only list creates a new list under the hood"