[not for merge] Warnings as errors in akka-actor (#26634)

Warnings as errors in akka-actor
This commit is contained in:
Arnout Engelen 2019-04-03 13:13:44 +02:00 committed by GitHub
parent 18802420fb
commit 76479b8770
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
68 changed files with 313 additions and 100 deletions

View file

@ -7,6 +7,7 @@ package akka.japi
import java.util.Collections.{ emptyList, singletonList }
import akka.util.Collections.EmptyImmutableSeq
import com.github.ghik.silencer.silent
import scala.collection.immutable
import scala.language.implicitConversions
@ -82,6 +83,7 @@ object Pair {
*
* This class is kept for compatibility, but for future API's please prefer [[akka.japi.function.Creator]].
*/
@silent
@SerialVersionUID(1L)
trait Creator[T] extends Serializable {
@ -241,7 +243,8 @@ object Util {
/**
* Turns an array into an immutable Scala sequence (by copying it).
*/
def immutableSeq[T](arr: Array[T]): immutable.Seq[T] = if ((arr ne null) && arr.length > 0) Vector(arr: _*) else Nil
def immutableSeq[T](arr: Array[T]): immutable.Seq[T] =
if ((arr ne null) && arr.length > 0) arr.toIndexedSeq else Nil
/**
* Turns an [[java.lang.Iterable]] into an immutable Scala sequence (by copying it).