Changes on code review
This commit is contained in:
Vendored
+18
@@ -0,0 +1,18 @@
|
||||
// "Surround callee with parenthesis" "true"
|
||||
|
||||
class A {
|
||||
val foo: B.(String, Int) -> Unit get() = null!!
|
||||
}
|
||||
|
||||
class B {
|
||||
fun getA() = A()
|
||||
}
|
||||
|
||||
|
||||
fun test(b: B) {
|
||||
with(b) {
|
||||
b.getA().<caret>foo("", 1)
|
||||
}
|
||||
}
|
||||
|
||||
public inline fun <T, R> with(receiver: T, f: T.() -> R): R = receiver.f()
|
||||
idea/testData/quickfix/migration/invokeOnExtensionFunctionWithExplicitReceiverFix/notSimple.kt.after
Vendored
+18
@@ -0,0 +1,18 @@
|
||||
// "Surround callee with parenthesis" "true"
|
||||
|
||||
class A {
|
||||
val foo: B.(String, Int) -> Unit get() = null!!
|
||||
}
|
||||
|
||||
class B {
|
||||
fun getA() = A()
|
||||
}
|
||||
|
||||
|
||||
fun test(b: B) {
|
||||
with(b) {
|
||||
(b.getA().foo)("", 1)
|
||||
}
|
||||
}
|
||||
|
||||
public inline fun <T, R> with(receiver: T, f: T.() -> R): R = receiver.f()
|
||||
Vendored
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Fix extension function value call" "true"
|
||||
// "Surround callee with parenthesis" "true"
|
||||
|
||||
class A {
|
||||
val foo: B.() -> Unit get() = null!!
|
||||
|
||||
Vendored
+1
-1
@@ -1,4 +1,4 @@
|
||||
// "Fix extension function value call" "true"
|
||||
// "Surround callee with parenthesis" "true"
|
||||
|
||||
class A {
|
||||
val foo: B.() -> Unit get() = null!!
|
||||
|
||||
Reference in New Issue
Block a user