K2: get rid of manual diagnostic suppression in checkers
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
abstract class A
|
||||
|
||||
fun foo(i: Int) {}
|
||||
|
||||
<!VALUE_CLASS_WITHOUT_JVM_INLINE_ANNOTATION!>value<!> class B(val i: Int) : @Suppress("VALUE_CLASS_CANNOT_EXTEND_CLASSES") A() {
|
||||
@Suppress("SECONDARY_CONSTRUCTOR_WITH_BODY_INSIDE_VALUE_CLASS")
|
||||
constructor() : this(42) {
|
||||
foo(i)
|
||||
}
|
||||
|
||||
@Suppress("ABSTRACT_PROPERTY_IN_NON_ABSTRACT_CLASS")
|
||||
abstract val y: Int
|
||||
}
|
||||
|
||||
interface C {
|
||||
@Suppress("PRIVATE_PROPERTY_IN_INTERFACE")
|
||||
private val x: Int
|
||||
|
||||
@Suppress("METHOD_OF_ANY_IMPLEMENTED_IN_INTERFACE")
|
||||
override fun hashCode() = 42
|
||||
}
|
||||
|
||||
<!MUST_BE_INITIALIZED!>@Suppress("PROPERTY_WITH_NO_TYPE_NO_INITIALIZER")
|
||||
val z<!>
|
||||
Reference in New Issue
Block a user