scala / collection-strawman

Implementation of the new Scala 2.13 Collections
Apache License 2.0
200 stars 72 forks source link

Can't collect on BitSet #507

Closed Ichoran closed 6 years ago

Ichoran commented 6 years ago
scala> val b = strawman.collection.immutable.BitSet(1)
b: strawman.collection.immutable.BitSet = BitSet.BitSet1(1)

scala> b.collect{ case x => x }
         ^
       error: ambiguous reference to overloaded definition,
       both method collect in trait StrictOptimizedIterableOps of type [B](pf: PartialFunction[Int,B])strawman.collection.immutable.Set[B]
       and  method collect in trait SortedSetOps of type [B](pf: PartialFunction[Int,B])(implicit evidence$6: Ordering[B])strawman.collection.immutable.SortedSet[B]
       match argument types (PartialFunction[Int,Int])
szeiger commented 6 years ago

probably needs a dummy override to fix the precedence