Infamously, Set
is invariant in its type parameter.
That seems to make the implicit not apply?
Maybe V
is not inferred correctly. Sometimes it likes to infer Nothing
.
(Posting a complete minimization would help someone help you.)
I'll try to decipher the -Ytyper-debug
when I get a chance, but FTR:
Succeeding on Seq:
| | | solving for (A: ?A)
| | | |-- seq2IndexMap BYVALmode-EXPRmode-FUNmode-POLYmode (silent: value b in Test) implicits disabled
| | | | [adapt] [T, V <: Code.this.Indexed[T]](s: Seq[V])Code.this.IndexM... adapted to [T, V <: Code.this.Indexed[T]](s: Seq[V])Code.this.IndexM...
| | | | \-> (s: Seq[V])nosetconvert.Test.IndexMap[T,V]
| | | solving for (T: ?T, V: ?V)
| | | [adapt] seq2IndexMap adapted to [T, V <: Code.this.Indexed[T]](s: Seq[V])Code.this.IndexM... based on pt Seq[nosetconvert.Test.ClassData] => nosetconvert.Test.NameMap[nosetconvert.Test.ClassData]
| | | |-- [T, V <: Code.this.Indexed[T]](s: Seq[V])Code.this.IndexM... : pt=nosetconvert.Test.NameMap[nosetconvert.Test.ClassData] BYVALmode-EXPRmode (silent: value b in Test) implicits disabled
| | | | \-> nosetconvert.Test.IndexMap[String,nosetconvert.Test.Named]
| | | [adapt] [A](elems: A*)CC[A] adapted to [T, V <: Code.this.Indexed[T]](s: Seq[V])Code.this.IndexM... based on pt nosetconvert.Test.NameMap[nosetconvert.Test.ClassData]
| | | \-> nosetconvert.Test.IndexMap[String,nosetconvert.Test.Named]
Failing on Set:
| | | solving for (A: ?A)
| | | |-- set2IndexMap BYVALmode-EXPRmode-FUNmode-POLYmode (silent: value c in Test) implicits disabled
| | | | [adapt] [T, V <: Code.this.Indexed[T]](s: Set[V])Code.this.IndexM... adapted to [T, V <: Code.this.Indexed[T]](s: Set[V])Code.this.IndexM...
| | | | \-> (s: Set[V])nosetconvert.Test.IndexMap[T,V]
| | | |-- nosetconvert.this.Test.set2IndexMap BYVALmode-EXPRmode-FUNmode-POLYmode (silent: value c in Test) implicits disabled
| | | | [adapt] [T, V <: Code.this.Indexed[T]](s: Set[V])Code.this.IndexM... adapted to [T, V <: Code.this.Indexed[T]](s: Set[V])Code.this.IndexM...
| | | | \-> (s: Set[V])nosetconvert.Test.IndexMap[T,V]
| | | \-> <error>