QuickFix: change overloaded operator parameter type or return type
This commit is contained in:
+7
@@ -0,0 +1,7 @@
|
||||
// "Change 'A.not' function return type to 'A'" "true"
|
||||
trait A {
|
||||
fun not(): A
|
||||
fun times(a: A): A
|
||||
}
|
||||
|
||||
fun foo(a: A): A = a * <caret>!(if (true) a else a)
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// "Change 'A.plus' function return type to '() -> Int'" "true"
|
||||
trait A {
|
||||
fun plus(a: A): () -> Int
|
||||
}
|
||||
|
||||
fun foo(a: A): () -> Int {
|
||||
return a + a<caret>
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
// "Change parameter 'a' type of function 'A.times' to 'String'" "true"
|
||||
trait A {
|
||||
fun times(a: String): A
|
||||
}
|
||||
|
||||
fun foo(a: A): A = a * <caret>""
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
// "Change 'A.not' function return type to 'A'" "true"
|
||||
trait A {
|
||||
fun not(): String
|
||||
fun times(a: A): A
|
||||
}
|
||||
|
||||
fun foo(a: A): A = a * <caret>!(if (true) a else a)
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// "Change 'A.plus' function return type to '() -> Int'" "true"
|
||||
trait A {
|
||||
fun plus(a: A): String
|
||||
}
|
||||
|
||||
fun foo(a: A): () -> Int {
|
||||
return a + a<caret>
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
// "Change parameter 'a' type of function 'A.times' to 'String'" "true"
|
||||
trait A {
|
||||
fun times(a: A): A
|
||||
}
|
||||
|
||||
fun foo(a: A): A = a * <caret>""
|
||||
Reference in New Issue
Block a user