KT-12100 convert try / finally to use: 'this' cases, implementation via resolved call
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
import java.io.Closeable
|
||||
|
||||
class MyCloseable : Closeable {
|
||||
override fun close() {}
|
||||
|
||||
fun process(x: Int) = x
|
||||
|
||||
fun Int.foo() {
|
||||
use { this@MyCloseable.process(this) }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user