Pull Up: Drop 'override' modifier if moved member doesn't override anything
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
open class A {
|
||||
}
|
||||
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class <caret>B : A(), I {
|
||||
// INFO: {"checked": "true", "toAbstract": "false"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
open class A {
|
||||
// INFO: {"checked": "true", "toAbstract": "false"}
|
||||
fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class B : A(), I {
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
open class A {
|
||||
}
|
||||
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class <caret>B : A(), I {
|
||||
// INFO: {"checked": "true", "toAbstract": "true"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
Vendored
+15
@@ -0,0 +1,15 @@
|
||||
abstract class A {
|
||||
// INFO: {"checked": "true", "toAbstract": "true"}
|
||||
abstract fun foo()
|
||||
}
|
||||
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class B : A(), I {
|
||||
// INFO: {"checked": "true", "toAbstract": "true"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
open class A {
|
||||
}
|
||||
|
||||
// INFO: {"checked": "true"}
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class <caret>B : A(), I {
|
||||
// INFO: {"checked": "true", "toAbstract": "false"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
Vendored
+14
@@ -0,0 +1,14 @@
|
||||
open class A : I {
|
||||
// INFO: {"checked": "true", "toAbstract": "false"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// INFO: {"checked": "true"}
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class B : A() {
|
||||
}
|
||||
Vendored
+14
@@ -0,0 +1,14 @@
|
||||
open class A {
|
||||
}
|
||||
|
||||
// INFO: {"checked": "true"}
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class <caret>B : A(), I {
|
||||
// INFO: {"checked": "true", "toAbstract": "true"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
abstract class A : I {
|
||||
// INFO: {"checked": "true", "toAbstract": "true"}
|
||||
abstract override fun foo()
|
||||
}
|
||||
|
||||
// INFO: {"checked": "true"}
|
||||
interface I {
|
||||
fun foo()
|
||||
}
|
||||
|
||||
class B : A() {
|
||||
// INFO: {"checked": "true", "toAbstract": "true"}
|
||||
override fun foo() {
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user