Files
kotlin-fork/idea/testData/quickfix/deprecatedSymbolUsage/operatorCalls/invoke4.kt
T
Toshiaki Kameyama be194c3460 ReplaceWith: suggest for "invoke" extension
#KT-8597 Fixed
2020-10-23 15:46:49 +09:00

17 lines
377 B
Kotlin
Vendored

// "Replace with 'execute(action)'" "true"
class Executor {
val self: Executor
get() = this
@Deprecated("Use Executor.execute(Runnable) instead.", ReplaceWith("execute(action)"))
operator fun invoke(action: () -> Unit) {}
fun execute(action: () -> Unit) {}
}
fun usage(executor: Executor) {
executor.<caret>self {
// do something
}
}