blob: 1fedc00238ff382d9071e9e4477a159abb53c4a3 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
package scala
package collection
package immutable
import HashMap.{ HashTrieMap, HashMapCollision1, HashMap1 }
import HashSet.{ HashTrieSet, HashSetCollision1, HashSet1 }
object i996{
private[this] def collisionToArray[T](x: Iterable[T]): Array[Iterable[T]] = (x match {
case x: HashMapCollision1[_, _] => x.kvs.map(x => HashMap(x)).toArray
case x: HashSetCollision1[_] => x.ks.map(x => HashSet(x)).toArray
}).asInstanceOf[Array[Iterable[T]]]
}
|