Introduce Variable: Avoid explicit types for expression of anonymous type
#KT-12078 Fixed
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
fun foo() {
|
||||
bar(<selection>object: Runnable {
|
||||
override fun run() {
|
||||
}
|
||||
}</selection>)
|
||||
}
|
||||
|
||||
fun bar(runnable: Runnable) {
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
fun foo() {
|
||||
val runnable = object : Runnable {
|
||||
override fun run() {
|
||||
}
|
||||
}
|
||||
bar(runnable)
|
||||
}
|
||||
|
||||
fun bar(runnable: Runnable) {
|
||||
}
|
||||
Reference in New Issue
Block a user