KT-7525 Don't suggest to replace 'get' call with index operator for static method calls (inspection & intention)

KT-5322 super.get issues a "Replace 'get' call with index operator" inspection

 #KT-7525 Fixed
 #KT-5322 Fixed
This commit is contained in:
Valentin Kipyatkov
2015-05-14 14:45:26 +03:00
parent 0fe334fd55
commit 4c88b31878
22 changed files with 230 additions and 9 deletions
@@ -0,0 +1,9 @@
class C {
companion object {
fun plus(s: String): C = C()
}
}
fun foo() {
C.<caret>plus("x")
}
@@ -0,0 +1,9 @@
class C {
companion object {
fun plus(s: String): C = C()
}
}
fun foo() {
C + "x"
}
@@ -0,0 +1,11 @@
// IS_APPLICABLE: false
open class Base {
open fun plus(s: String) = ""
}
class C : Base() {
override fun plus(s: String): String {
return super.<caret>plus(s)
}
}