Drop unnecessary suppress from stdlib

^KT-62785 Fixed
Review: https://jetbrains.team/p/kt/reviews/12858/files
This commit is contained in:
Nikita Bobko
2023-11-06 12:20:46 +01:00
committed by Space Team
parent aad19ab844
commit 4050285fef
21 changed files with 3 additions and 82 deletions
@@ -10,10 +10,6 @@ package kotlin.reflect
*
* @param R return type of the callable.
*/
@Suppress(
"ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING",
"ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING"
) // Can be dropped after bootstrap update
public actual interface KCallable<out R> : KAnnotatedElement {
/**
* The name of this callable as it was declared in the source code.
@@ -29,6 +25,5 @@ public actual interface KCallable<out R> : KAnnotatedElement {
/**
* The type of values returned by this callable.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val returnType: KType
}
@@ -13,7 +13,6 @@ package kotlin.reflect
*
* @param T the type of the class.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedElement, KClassifier {
/**
* The simple name of the class as it was declared in the source code,
@@ -12,7 +12,6 @@ package kotlin.collections
*
* @param E the type of elements contained in the collection. The collection is invariant in its element type.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableCollection<E> protected actual constructor() : AbstractCollection<E>(), MutableCollection<E> {
actual abstract override fun add(element: E): Boolean
@@ -57,7 +56,6 @@ public actual abstract class AbstractMutableCollection<E> protected actual const
}
}
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@Deprecated("Provided so that subclasses inherit this function", level = DeprecationLevel.HIDDEN)
@JsName("toJSON")
protected fun toJSON(): Any = this.toArray()
@@ -67,7 +65,6 @@ public actual abstract class AbstractMutableCollection<E> protected actual const
* This method is called every time when a mutating method is called on this mutable collection.
* Mutable collections that are built (frozen) must throw `UnsupportedOperationException`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
internal open fun checkIsMutable(): Unit { }
}
@@ -17,12 +17,7 @@ package kotlin.collections
*
* @param E the type of elements contained in the list. The list is invariant in its element type.
*/
@Suppress(
"ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING",
"ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING"
) // Can be dropped after bootstrap update
public actual abstract class AbstractMutableList<E> protected actual constructor() : AbstractMutableCollection<E>(), MutableList<E> {
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
protected var modCount: Int = 0
abstract override fun add(index: Int, element: E): Unit
@@ -86,7 +81,6 @@ public actual abstract class AbstractMutableList<E> protected actual constructor
/**
* Removes the range of elements from this list starting from [fromIndex] and ending with but not including [toIndex].
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
protected open fun removeRange(fromIndex: Int, toIndex: Int) {
val iterator = listIterator(fromIndex)
repeat(toIndex - fromIndex) {
@@ -18,12 +18,9 @@ package kotlin.collections
* @param K the type of map keys. The map is invariant in its key type.
* @param V the type of map values. The map is invariant in its value type.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableMap<K, V> protected actual constructor() : AbstractMap<K, V>(), MutableMap<K, V> {
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
internal open fun createKeysView(): MutableSet<K> = HashMapKeysDefault(this)
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
internal open fun createValuesView(): MutableCollection<V> = HashMapValuesDefault(this)
private var keysView: MutableSet<K>? = null
@@ -68,6 +65,5 @@ public actual abstract class AbstractMutableMap<K, V> protected actual construct
* This method is called every time when a mutating method is called on this mutable map.
* Mutable maps that are built (frozen) must throw `UnsupportedOperationException`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
internal open fun checkIsMutable() {}
}
@@ -9,7 +9,6 @@ package kotlin.collections
*
* @param E the type of elements contained in the set. The set is invariant in its element type.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableSet<E> protected actual constructor() : AbstractMutableCollection<E>(), MutableSet<E> {
/**
@@ -28,5 +28,4 @@ package kotlin
@Suppress("NO_ACTUAL_CLASS_MEMBER_FOR_EXPECTED_CLASS")
@SinceKotlin("1.3") public actual typealias ConcurrentModificationException = java.util.ConcurrentModificationException
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1") public actual typealias Comparator<T> = java.util.Comparator<T>
@@ -7,7 +7,6 @@
package kotlin.text
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1") public actual typealias Appendable = java.lang.Appendable
@Suppress("ACTUAL_WITHOUT_EXPECT") // TODO: some supertypes are missing
@@ -13,7 +13,6 @@ import java.util.AbstractCollection
* @param E the type of elements contained in the collection. The collection is invariant in its element type.
*/
@SinceKotlin("1.1")
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableCollection<E> protected actual constructor() : MutableCollection<E>, AbstractCollection<E>() {
/**
* Adds the specified element to the collection.
@@ -13,7 +13,6 @@ import java.util.AbstractList
* @param E the type of elements contained in the list. The list is invariant in its element type.
*/
@SinceKotlin("1.1")
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableList<E> protected actual constructor() : MutableList<E>, AbstractList<E>() {
/**
* Replaces the element at the specified position in this list with the specified element.
@@ -16,7 +16,6 @@ import java.util.AbstractMap
* @param V the type of map values. The map is invariant in its value type.
*/
@SinceKotlin("1.1")
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableMap<K, V> protected actual constructor() : MutableMap<K, V>, AbstractMap<K, V>() {
/**
* Associates the specified [value] with the specified [key] in the map.
@@ -13,7 +13,6 @@ import java.util.AbstractSet
* @param E the type of elements contained in the set. The set is invariant in its element type.
*/
@SinceKotlin("1.1")
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableSet<E> protected actual constructor() : MutableSet<E>, AbstractSet<E>() {
/**
* Adds the specified element to the set.
@@ -10,7 +10,6 @@ package kotlin.reflect
*
* @param R return type of the callable.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KCallable<out R> : KAnnotatedElement {
/**
* The name of this callable as it was declared in the source code.
@@ -28,19 +27,16 @@ public actual interface KCallable<out R> : KAnnotatedElement {
* If this callable requires a `this` instance or an extension receiver parameter,
* they come first in the list in that order.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val parameters: List<KParameter>
/**
* The type of values returned by this callable.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val returnType: KType
/**
* The list of type parameters of this callable.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val typeParameters: List<KTypeParameter>
@@ -49,7 +45,6 @@ public actual interface KCallable<out R> : KAnnotatedElement {
* Throws an exception if the number of specified arguments is not equal to the size of [parameters],
* or if their types do not match the types of the parameters.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public fun call(vararg args: Any?): R
/**
@@ -57,41 +52,35 @@ public actual interface KCallable<out R> : KAnnotatedElement {
* If a parameter is not found in the mapping and is not optional (as per [KParameter.isOptional]),
* or its type does not match the type of the provided value, an exception is thrown.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public fun callBy(args: Map<KParameter, Any?>): R
/**
* Visibility of this callable, or `null` if its visibility cannot be represented in Kotlin.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val visibility: KVisibility?
/**
* `true` if this callable is `final`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isFinal: Boolean
/**
* `true` if this callable is `open`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isOpen: Boolean
/**
* `true` if this callable is `abstract`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isAbstract: Boolean
/**
* `true` if this is a suspending function.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.3")
public val isSuspend: Boolean
}
@@ -13,7 +13,6 @@ package kotlin.reflect
*
* @param T the type of the class.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedElement, KClassifier {
/**
* The simple name of the class as it was declared in the source code,
@@ -31,25 +30,21 @@ public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedEleme
* All functions and properties accessible in this class, including those declared in this class
* and all of its superclasses. Does not include constructors.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
override val members: Collection<KCallable<*>>
/**
* All constructors declared in this class.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val constructors: Collection<KFunction<T>>
/**
* All classes declared inside this class. This includes both inner and static nested classes.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val nestedClasses: Collection<KClass<*>>
/**
* The instance of the object declaration, or `null` if this class is not an object declaration.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val objectInstance: T?
/**
@@ -61,49 +56,42 @@ public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedEleme
/**
* The list of type parameters of this class. This list does *not* include type parameters of outer classes.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val typeParameters: List<KTypeParameter>
/**
* The list of immediate supertypes of this class, in the order they are listed in the source code.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val supertypes: List<KType>
/**
* The list of the immediate subclasses if this class is a sealed class, or an empty list otherwise.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.3")
public val sealedSubclasses: List<KClass<out T>>
/**
* Visibility of this class, or `null` if its visibility cannot be represented in Kotlin.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val visibility: KVisibility?
/**
* `true` if this class is `final`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isFinal: Boolean
/**
* `true` if this class is `open`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isOpen: Boolean
/**
* `true` if this class is `abstract`.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isAbstract: Boolean
@@ -112,7 +100,6 @@ public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedEleme
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/sealed-classes.html)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isSealed: Boolean
@@ -122,7 +109,6 @@ public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedEleme
* [data object](https://kotlinlang.org/docs/object-declarations.html#data-objects)
* in the Kotlin language documentation.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isData: Boolean
@@ -131,7 +117,6 @@ public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedEleme
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/nested-classes.html#inner-classes)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isInner: Boolean
@@ -140,21 +125,18 @@ public actual interface KClass<T : Any> : KDeclarationContainer, KAnnotatedEleme
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/object-declarations.html#companion-objects)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isCompanion: Boolean
/**
* `true` if this class is a Kotlin functional interface.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.4")
public val isFun: Boolean
/**
* `true` if this class is a value class.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.5")
public val isValue: Boolean
@@ -8,14 +8,12 @@ package kotlin.reflect
/**
* Represents a function with introspection capabilities.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KFunction<out R> : KCallable<R>, Function<R> {
/**
* `true` if this function is `inline`.
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/inline-functions.html)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isInline: Boolean
@@ -24,7 +22,6 @@ public actual interface KFunction<out R> : KCallable<R>, Function<R> {
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/java-interop.html#using-jni-with-kotlin)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isExternal: Boolean
@@ -33,7 +30,6 @@ public actual interface KFunction<out R> : KCallable<R>, Function<R> {
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/operator-overloading.html)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isOperator: Boolean
@@ -42,7 +38,6 @@ public actual interface KFunction<out R> : KCallable<R>, Function<R> {
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/functions.html#infix-notation)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isInfix: Boolean
@@ -15,14 +15,12 @@ package kotlin.reflect
*
* @param V the type of the property value.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KProperty<out V> : KCallable<V> {
/**
* `true` if this property is `lateinit`.
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/properties.html#late-initialized-properties)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isLateinit: Boolean
@@ -31,12 +29,10 @@ public actual interface KProperty<out V> : KCallable<V> {
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/properties.html#compile-time-constants)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public val isConst: Boolean
/** The getter of this property, used to obtain the value of the property. */
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val getter: Getter<V>
/**
@@ -60,10 +56,8 @@ public actual interface KProperty<out V> : KCallable<V> {
/**
* Represents a property declared as a `var`.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KMutableProperty<V> : KProperty<V> {
/** The setter of this mutable property, used to change the value of the property. */
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
public val setter: Setter<V>
/**
@@ -78,7 +72,7 @@ public actual interface KMutableProperty<V> : KProperty<V> {
* Such property is either originally declared in a receiverless context such as a package,
* or has the receiver bound to it.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Covariant 'setter' override. The suppress can be dropped in K2 KT-61184
public actual interface KProperty0<out V> : KProperty<V>, () -> V {
/**
* Returns the current value of the property.
@@ -90,7 +84,6 @@ public actual interface KProperty0<out V> : KProperty<V>, () -> V {
* See the [Kotlin language documentation](https://kotlinlang.org/docs/reference/delegated-properties.html)
* for more information.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public fun getDelegate(): Any?
@@ -135,7 +128,7 @@ public actual interface KMutableProperty0<V> : KProperty0<V>, KMutableProperty<V
* @param T the type of the receiver which should be used to obtain the value of the property.
* @param V the type of the property value.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Covariant 'getter' override. The suppress can be dropped in K2 KT-61184
public actual interface KProperty1<T, out V> : KProperty<V>, (T) -> V {
/**
* Returns the current value of the property.
@@ -160,7 +153,6 @@ public actual interface KProperty1<T, out V> : KProperty<V>, (T) -> V {
*
* @see [kotlin.reflect.full.getExtensionDelegate] // [KProperty1.getExtensionDelegate]
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public fun getDelegate(receiver: T): Any?
@@ -212,7 +204,7 @@ public actual interface KMutableProperty1<T, V> : KProperty1<T, V>, KMutableProp
* the type of the extension receiver.
* @param V the type of the property value.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Covariant 'getter' override. The suppress can be dropped in K2 KT-61184
public actual interface KProperty2<D, E, out V> : KProperty<V>, (D, E) -> V {
/**
* Returns the current value of the property. In case of the extension property in a class,
@@ -236,7 +228,6 @@ public actual interface KProperty2<D, E, out V> : KProperty<V>, (D, E) -> V {
*
* @see [kotlin.reflect.full.getExtensionDelegate] // [KProperty2.getExtensionDelegate]
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public fun getDelegate(receiver1: D, receiver2: E): Any?
@@ -9,7 +9,6 @@ package kotlin.reflect
* Represents a type. Type is usually either a class with optional type arguments,
* or a type parameter of some declaration, plus nullability.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual interface KType : KAnnotatedElement {
/**
* The declaration of the classifier used in this type.
@@ -10,7 +10,6 @@ package kotlin.collections
*
* @param E the type of elements contained in the collection. The collection is invariant in its element type.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
public actual abstract class AbstractMutableCollection<E> protected actual constructor(): MutableCollection<E>, AbstractCollection<E>() {
// Bulk Modification Operations
@@ -17,10 +17,6 @@ package kotlin.collections
*
* @param E the type of elements contained in the list. The list is invariant in its element type.
*/
@Suppress(
"ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING",
"ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING"
) // Can be dropped after bootstrap update
public actual abstract class AbstractMutableList<E> protected actual constructor() : AbstractMutableCollection<E>(), MutableList<E> {
/**
* The number of times this list is structurally modified.
@@ -32,7 +28,6 @@ public actual abstract class AbstractMutableList<E> protected actual constructor
* to provide fail-fast behavoir when a concurrent modification is detected during iteration.
* [ConcurrentModificationException] will be thrown in this case.
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
protected var modCount: Int = 0
abstract override fun add(index: Int, element: E): Unit
@@ -86,7 +81,6 @@ public actual abstract class AbstractMutableList<E> protected actual constructor
/**
* Removes the range of elements from this list starting from [fromIndex] and ending with but not including [toIndex].
*/
@Suppress("NON_ACTUAL_MEMBER_DECLARED_IN_EXPECT_NON_FINAL_CLASSIFIER_ACTUALIZATION_WARNING") // Can be dropped after bootstrap update
protected open fun removeRange(fromIndex: Int, toIndex: Int) {
val iterator = listIterator(fromIndex)
repeat(toIndex - fromIndex) {
@@ -8,7 +8,6 @@ package kotlin.collections
* @param K the type of map keys. The map is invariant in its key type.
* @param V the type of map values. The map is invariant in its value type.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public actual abstract class AbstractMutableMap<K, V> protected actual constructor() : AbstractMap<K, V>(), MutableMap<K, V> {
/**
@@ -5,7 +5,6 @@ package kotlin.collections
*
* @param E the type of elements contained in the set. The set is invariant in its element type.
*/
@Suppress("ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_MEMBERS_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING", "ACTUAL_CLASSIFIER_MUST_HAVE_THE_SAME_SUPERTYPES_AS_NON_FINAL_EXPECT_CLASSIFIER_WARNING") // Can be dropped after bootstrap update
@SinceKotlin("1.1")
public actual abstract class AbstractMutableSet<E> protected actual constructor() : AbstractMutableCollection<E>(), MutableSet<E> {
/**