import java.util.ArrayList // "Create extension function 'set'" "true" // WITH_RUNTIME class Foo { fun x (y: Any, w: java.util.ArrayList) { y["", w] = w } } operator fun Any.set(s: String, w: ArrayList, value: ArrayList) { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. }