+- Signs in Generic Declaration in Scala

前端 未结 3 1237
走了就别回头了
走了就别回头了 2021-01-30 20:33

I was looking at the documentation for PartialFunction in this link:

trait PartialFunction[-A, +B] extends (A) ⇒ B

Maybe someone can help clari

3条回答
  •  逝去的感伤
    2021-01-30 21:05

    To supplement the other answers, here is a link to the documentation for variances on the scala-lang site:

    https://docs.scala-lang.org/tour/variances.html

提交回复
热议问题