"Remove redundant receiver" quick fix: Remove unused type parameter #KT-23512
This commit is contained in:
committed by
Mikhail Glukhikh
parent
0cd25353bc
commit
90529dfda4
+5
@@ -0,0 +1,5 @@
|
||||
fun <T> <caret>T.foo() {}
|
||||
|
||||
fun test() {
|
||||
"".foo()
|
||||
}
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
fun foo() {}
|
||||
|
||||
fun test() {
|
||||
foo()
|
||||
}
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
fun <T> <caret>T.foo(t: T) {}
|
||||
|
||||
fun test() {
|
||||
"".foo("")
|
||||
}
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
fun <T> foo(t: T) {}
|
||||
|
||||
fun test() {
|
||||
foo("")
|
||||
}
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
interface TypeHolder<T, U>
|
||||
|
||||
fun <T, U> <caret>TypeHolder<T, U>.foo() {}
|
||||
|
||||
fun test(holder: TypeHolder<String, Int>) {
|
||||
holder.foo()
|
||||
}
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
interface TypeHolder<T, U>
|
||||
|
||||
fun foo() {}
|
||||
|
||||
fun test(holder: TypeHolder<String, Int>) {
|
||||
foo()
|
||||
}
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
class Test<T> {
|
||||
fun <caret>T.foo() {}
|
||||
|
||||
fun test(t: T) {
|
||||
t.foo()
|
||||
}
|
||||
}
|
||||
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
class Test<T> {
|
||||
fun foo() {}
|
||||
|
||||
fun test(t: T) {
|
||||
foo()
|
||||
}
|
||||
}
|
||||
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
class Test<T> {
|
||||
fun <U> <caret>U.foo() {}
|
||||
|
||||
fun test() {
|
||||
"".foo()
|
||||
}
|
||||
}
|
||||
Vendored
+7
@@ -0,0 +1,7 @@
|
||||
class Test<T> {
|
||||
fun foo() {}
|
||||
|
||||
fun test() {
|
||||
foo()
|
||||
}
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
val <T> <caret>T.bar: Int
|
||||
get() = 1
|
||||
|
||||
fun test() {
|
||||
"".bar
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
val bar: Int
|
||||
get() = 1
|
||||
|
||||
fun test() {
|
||||
bar
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
class Test<T> {
|
||||
val <caret>T.bar: Int
|
||||
get() = 1
|
||||
|
||||
fun test(t: T) {
|
||||
t.bar
|
||||
}
|
||||
}
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
class Test<T> {
|
||||
val bar: Int
|
||||
get() = 1
|
||||
|
||||
fun test(t: T) {
|
||||
bar
|
||||
}
|
||||
}
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
class Test<T> {
|
||||
val <S> <caret>S.bar: Int
|
||||
get() = 1
|
||||
|
||||
fun test() {
|
||||
"".bar
|
||||
}
|
||||
}
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
class Test<T> {
|
||||
val bar: Int
|
||||
get() = 1
|
||||
|
||||
fun test() {
|
||||
bar
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user