FIR IDE: Check function call before trying to drop the receiver
This commit is contained in:
+12
@@ -0,0 +1,12 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
import test.Obj.funFromObj
|
||||
|
||||
object Obj {
|
||||
fun funFromObj() {}
|
||||
}
|
||||
|
||||
fun usage() {
|
||||
<selection>Obj.funFromObj()</selection>
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
import test.Obj.funFromObj
|
||||
|
||||
object Obj {
|
||||
fun funFromObj() {}
|
||||
}
|
||||
|
||||
fun usage() {
|
||||
funFromObj()
|
||||
}
|
||||
Vendored
+12
@@ -0,0 +1,12 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
class T {
|
||||
companion object
|
||||
}
|
||||
|
||||
fun T.Companion.ext() {}
|
||||
|
||||
fun usage() {
|
||||
<selection>T.ext()</selection>
|
||||
}
|
||||
Vendored
+12
@@ -0,0 +1,12 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
class T {
|
||||
companion object
|
||||
}
|
||||
|
||||
fun T.Companion.ext() {}
|
||||
|
||||
fun usage() {
|
||||
T.ext()
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
object T
|
||||
|
||||
fun T.ext() {}
|
||||
|
||||
fun usage() {
|
||||
<selection>T.ext()</selection>
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
object T
|
||||
|
||||
fun T.ext() {}
|
||||
|
||||
fun usage() {
|
||||
T.ext()
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
class T
|
||||
|
||||
fun T.ext() {}
|
||||
|
||||
fun usage(t: T) {
|
||||
<selection>t.ext()</selection>
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
// FIR_COMPARISON
|
||||
package test
|
||||
|
||||
class T
|
||||
|
||||
fun T.ext() {}
|
||||
|
||||
fun usage(t: T) {
|
||||
t.ext()
|
||||
}
|
||||
Reference in New Issue
Block a user