Files
kotlin-fork/compiler/testData/codegen/box/regressions/lambdaPostponeConstruction.kt
T
2019-11-19 11:00:09 +03:00

15 lines
280 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
class MyList<T>
operator fun <T> MyList<T>.plusAssign(element: T) {}
val listOfFunctions = MyList<(Int) -> Int>()
fun foo() {
listOfFunctions.plusAssign({ it -> it })
listOfFunctions += { it -> it }
}
fun box(): String {
return "OK"
}