abstract
modifier in interface detected KT-W1054In Kotlin, the abstract
keyword is redundant when declaring interfaces and their members. Interfaces are implicitly abstract in Kotlin, so there is no need to use the
abstract
keyword, and the same is true for any members of an interface. Omitting the abstract
keyword does not
affect the behavior or functionality of an interface, and allows for more concise code.
abstract interface Foo { // abstract keyword not needed
abstract fun x() // abstract keyword not needed
abstract var y: Int // abstract keyword not needed
}
Remove the abstract
modifier, since it's redundant.
interface Foo {
fun x()
var y: Int
}