Suppress most of unused parameter warnings
This commit is contained in:
@@ -21,7 +21,8 @@ val builtInsHeader = """@file:Suppress(
|
|||||||
"MUST_BE_INITIALIZED_OR_BE_ABSTRACT",
|
"MUST_BE_INITIALIZED_OR_BE_ABSTRACT",
|
||||||
"EXTERNAL_TYPE_EXTENDS_NON_EXTERNAL_TYPE",
|
"EXTERNAL_TYPE_EXTENDS_NON_EXTERNAL_TYPE",
|
||||||
"PRIMARY_CONSTRUCTOR_DELEGATION_CALL_EXPECTED",
|
"PRIMARY_CONSTRUCTOR_DELEGATION_CALL_EXPECTED",
|
||||||
"WRONG_MODIFIER_TARGET"
|
"WRONG_MODIFIER_TARGET",
|
||||||
|
"UNUSED_PARAMETER"
|
||||||
)
|
)
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -8,7 +8,8 @@
|
|||||||
"MUST_BE_INITIALIZED_OR_BE_ABSTRACT",
|
"MUST_BE_INITIALIZED_OR_BE_ABSTRACT",
|
||||||
"EXTERNAL_TYPE_EXTENDS_NON_EXTERNAL_TYPE",
|
"EXTERNAL_TYPE_EXTENDS_NON_EXTERNAL_TYPE",
|
||||||
"PRIMARY_CONSTRUCTOR_DELEGATION_CALL_EXPECTED",
|
"PRIMARY_CONSTRUCTOR_DELEGATION_CALL_EXPECTED",
|
||||||
"WRONG_MODIFIER_TARGET"
|
"WRONG_MODIFIER_TARGET",
|
||||||
|
"UNUSED_PARAMETER"
|
||||||
)
|
)
|
||||||
|
|
||||||
package kotlin
|
package kotlin
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
// Auto-generated file. DO NOT EDIT!
|
// Auto-generated file. DO NOT EDIT!
|
||||||
@file:Suppress("NON_ABSTRACT_FUNCTION_WITH_NO_BODY")
|
@file:Suppress("NON_ABSTRACT_FUNCTION_WITH_NO_BODY", "UNUSED_PARAMETER")
|
||||||
|
|
||||||
package kotlin
|
package kotlin
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -35,6 +35,7 @@ public inline operator fun <V, V1 : V> Map<in String, @Exact V>.getValue(thisRef
|
|||||||
public inline operator fun <V, V1 : V> MutableMap<in String, out @Exact V>.getValue(thisRef: Any?, property: KProperty<*>): V1 =
|
public inline operator fun <V, V1 : V> MutableMap<in String, out @Exact V>.getValue(thisRef: Any?, property: KProperty<*>): V1 =
|
||||||
@Suppress("UNCHECKED_CAST") (getOrImplicitDefault(property.name) as V1)
|
@Suppress("UNCHECKED_CAST") (getOrImplicitDefault(property.name) as V1)
|
||||||
|
|
||||||
|
@Suppress("UNUSED_PARAMETER")
|
||||||
@Deprecated("Use getValue() with two type parameters instead", level = DeprecationLevel.ERROR)
|
@Deprecated("Use getValue() with two type parameters instead", level = DeprecationLevel.ERROR)
|
||||||
@kotlin.jvm.JvmName("getVarContravariant")
|
@kotlin.jvm.JvmName("getVarContravariant")
|
||||||
@kotlin.internal.LowPriorityInOverloadResolution
|
@kotlin.internal.LowPriorityInOverloadResolution
|
||||||
|
|||||||
@@ -94,6 +94,7 @@ public abstract class TimeMark {
|
|||||||
"Subtracting one TimeMark from another is not a well defined operation because these time marks could have been obtained from the different time sources.",
|
"Subtracting one TimeMark from another is not a well defined operation because these time marks could have been obtained from the different time sources.",
|
||||||
level = DeprecationLevel.ERROR
|
level = DeprecationLevel.ERROR
|
||||||
)
|
)
|
||||||
|
@Suppress("UNUSED_PARAMETER")
|
||||||
public inline operator fun TimeMark.minus(other: TimeMark): Duration = throw Error("Operation is disallowed.")
|
public inline operator fun TimeMark.minus(other: TimeMark): Duration = throw Error("Operation is disallowed.")
|
||||||
|
|
||||||
@ExperimentalTime
|
@ExperimentalTime
|
||||||
@@ -103,6 +104,7 @@ public inline operator fun TimeMark.minus(other: TimeMark): Duration = throw Err
|
|||||||
"Comparing one TimeMark to another is not a well defined operation because these time marks could have been obtained from the different time sources.",
|
"Comparing one TimeMark to another is not a well defined operation because these time marks could have been obtained from the different time sources.",
|
||||||
level = DeprecationLevel.ERROR
|
level = DeprecationLevel.ERROR
|
||||||
)
|
)
|
||||||
|
@Suppress("UNUSED_PARAMETER")
|
||||||
public inline operator fun TimeMark.compareTo(other: TimeMark): Int = throw Error("Operation is disallowed.")
|
public inline operator fun TimeMark.compareTo(other: TimeMark): Int = throw Error("Operation is disallowed.")
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2010-2019 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
|
||||||
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -89,7 +89,7 @@ class ArrayDequeTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun clear() = testArrayDeque { bufferSize: Int, dequeSize: Int, head: Int, tail: Int ->
|
fun clear() = testArrayDeque { bufferSize: Int, _: Int, head: Int, tail: Int ->
|
||||||
val deque = generateArrayDeque(head, tail, bufferSize).apply { clear() }
|
val deque = generateArrayDeque(head, tail, bufferSize).apply { clear() }
|
||||||
assertTrue(deque.isEmpty())
|
assertTrue(deque.isEmpty())
|
||||||
}
|
}
|
||||||
@@ -543,7 +543,7 @@ class ArrayDequeTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun removeAll() = testArrayDeque { bufferSize: Int, dequeSize: Int, head: Int, tail: Int ->
|
fun removeAll() = testArrayDeque { bufferSize: Int, _: Int, head: Int, tail: Int ->
|
||||||
generateArrayDeque(head, tail, bufferSize).let { deque ->
|
generateArrayDeque(head, tail, bufferSize).let { deque ->
|
||||||
deque.removeAll(emptyList())
|
deque.removeAll(emptyList())
|
||||||
assertEquals((head until tail).toList(), deque)
|
assertEquals((head until tail).toList(), deque)
|
||||||
@@ -565,7 +565,7 @@ class ArrayDequeTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun retainAll() = testArrayDeque { bufferSize: Int, dequeSize: Int, head: Int, tail: Int ->
|
fun retainAll() = testArrayDeque { bufferSize: Int, _: Int, head: Int, tail: Int ->
|
||||||
val listToRetain = (head..tail).filter { Random.nextBoolean() }
|
val listToRetain = (head..tail).filter { Random.nextBoolean() }
|
||||||
|
|
||||||
val elements = (head until tail).toMutableList().apply { retainAll(listToRetain) }
|
val elements = (head until tail).toMutableList().apply { retainAll(listToRetain) }
|
||||||
|
|||||||
Reference in New Issue
Block a user