bezpośrednim rekursji prostu działa:pośrednie rekurencyjne definicje typów generycznych w Scala
trait TT[T<:TT[T]]
Ale mogę się jedną pośrednią z naiwnego podejścia
trait UU[V <: VV[UU[V]]]
trait VV[U <: UU[VV[U]]]
dać mi błąd:
CyclicTraits.scala:23: error: type arguments [UU[V]] do not conform to
trait VV's type parameter bounds [U <: UU[VV[U]]]
trait UU[V <: VV[UU[V]]]
^
CyclicTraits.scala:25: error: type arguments [VV[U]] do not conform to
trait UU's type parameter bounds [V <: VV[UU[V]]]
trait VV[U <: UU[VV[U]]]
^
W jaki sposób należy poprawnie wyrazić rekurencję parametru typu pośredniego?