chore: Drop @unused annotation from pekko (#2241)
This commit is contained in:
parent
5657514b39
commit
4f2434b650
115 changed files with 410 additions and 377 deletions
|
|
@ -31,13 +31,14 @@
|
|||
|
||||
package org.apache.pekko.cluster.ddata
|
||||
|
||||
import scala.annotation.nowarn
|
||||
import scala.annotation.tailrec
|
||||
import scala.collection.immutable
|
||||
|
||||
import org.apache.pekko
|
||||
import pekko.annotation.InternalApi
|
||||
import pekko.cluster.UniqueAddress
|
||||
import pekko.util.{ unused, HashCode }
|
||||
import pekko.util.HashCode
|
||||
|
||||
object ORSet {
|
||||
private val _empty: ORSet[Any] = new ORSet(Map.empty, VersionVector.empty)
|
||||
|
|
@ -401,7 +402,7 @@ final class ORSet[A] private[pekko] (
|
|||
* [[ORSet#remove(node:org\.apache\.pekko\.cluster\.ddata\.SelfUniqueAddress*]]
|
||||
* for each element, but it is more efficient.
|
||||
*/
|
||||
def clear(@unused node: SelfUniqueAddress): ORSet[A] = clear()
|
||||
def clear(@nowarn("msg=never used") node: SelfUniqueAddress): ORSet[A] = clear()
|
||||
|
||||
/**
|
||||
* INTERNAL API
|
||||
|
|
|
|||
|
|
@ -13,12 +13,13 @@
|
|||
|
||||
package org.apache.pekko.cluster.ddata
|
||||
|
||||
import scala.annotation.nowarn
|
||||
|
||||
import org.apache.pekko
|
||||
import pekko.actor.Address
|
||||
import pekko.annotation.InternalApi
|
||||
import pekko.cluster.Member
|
||||
import pekko.cluster.UniqueAddress
|
||||
import pekko.util.unused
|
||||
|
||||
/**
|
||||
* INTERNAL API
|
||||
|
|
@ -33,7 +34,7 @@ import pekko.util.unused
|
|||
}
|
||||
final case class PruningPerformed(obsoleteTime: Long) extends PruningState {
|
||||
def isObsolete(currentTime: Long): Boolean = obsoleteTime <= currentTime
|
||||
def addSeen(@unused node: Address): PruningState = this
|
||||
def addSeen(@nowarn("msg=never used") node: Address): PruningState = this
|
||||
def estimatedSize: Int = EstimatedSize.LongValue
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@
|
|||
|
||||
package org.apache.pekko.cluster.ddata.protobuf
|
||||
|
||||
import scala.annotation.nowarn
|
||||
import scala.concurrent.duration._
|
||||
|
||||
import org.apache.pekko
|
||||
|
|
@ -34,7 +35,7 @@ import pekko.cluster.ddata.Replicator.Internal._
|
|||
import pekko.cluster.ddata.VersionVector
|
||||
import pekko.remote.RARP
|
||||
import pekko.testkit.TestKit
|
||||
import pekko.util.{ unused, ByteString }
|
||||
import pekko.util.ByteString
|
||||
|
||||
import org.scalatest.BeforeAndAfterAll
|
||||
import org.scalatest.matchers.should.Matchers
|
||||
|
|
@ -265,7 +266,7 @@ class ReplicatorMessageSerializerSpec
|
|||
|
||||
"suppory getOrAdd" in {
|
||||
var n = 0
|
||||
def createValue(@unused a: Read): AnyRef = {
|
||||
def createValue(@nowarn("msg=never used") a: Read): AnyRef = {
|
||||
n += 1
|
||||
new AnyRef {
|
||||
override val toString = "v" + n
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue