Join type parameters in FunctionalBuilder

13 views
Skip to first unread message

falconepl

unread,
Jul 29, 2015, 6:11:15 AM7/29/15
to play-framework

I’ve been trying to dive into Play’s functional internals and I’ve stumbled upon join method in FunctionalBuilder:

  def join[A >: A1](implicit witness1: <:<[A, A1], witness2: <:<[A, A2], fu: ContravariantFunctor[M]): M[A] =
    apply[A]((a: A) => (a: A1, a: A2))(fu)

My question is - why we specify that A >: A1 while we expect to implicitly get witness1 that effectively specifies A <: A1. Why not to have A =:= A1 witness then?

Reply all
Reply to author
Forward
0 new messages