@@ -30,15 +30,16 @@ final class TreeMap[K, +V] private (tree: RB.Tree[K, V])(implicit val ordering:
30
30
with SortedMap [K , V ]
31
31
with SortedMapOps [K , V , TreeMap , TreeMap [K , V ]]
32
32
with StrictOptimizedIterableOps [(K , V ), Iterable , TreeMap [K , V ]]
33
+ with StrictOptimizedMapOps [K , V , Map , TreeMap [K , V ]]
33
34
with StrictOptimizedSortedMapOps [K , V , TreeMap , TreeMap [K , V ]] {
34
35
35
36
def this ()(implicit ordering : Ordering [K ]) = this (null )(ordering)
36
37
37
38
override def sortedMapFactory = TreeMap
38
39
39
- def iterator : collection. Iterator [(K , V )] = RB .iterator(tree)
40
+ def iterator : Iterator [(K , V )] = RB .iterator(tree)
40
41
41
- def keysIteratorFrom (start : K ): collection. Iterator [K ] = RB .keysIterator(tree, Some (start))
42
+ def keysIteratorFrom (start : K ): Iterator [K ] = RB .keysIterator(tree, Some (start))
42
43
43
44
def iteratorFrom (start : K ): Iterator [(K , V )] = RB .iterator(tree, Some (start))
44
45
@@ -152,7 +153,7 @@ object TreeMap extends SortedMapFactory[TreeMap] {
152
153
153
154
def empty [K : Ordering , V ]: TreeMap [K , V ] = new TreeMap ()
154
155
155
- def from [K : Ordering , V ](it : collection. IterableOnce [(K , V )]): TreeMap [K , V ] =
156
+ def from [K : Ordering , V ](it : IterableOnce [(K , V )]): TreeMap [K , V ] =
156
157
it match {
157
158
case tm : TreeMap [K , V ] => tm
158
159
case _ => (newBuilder[K , V ] ++= it).result()
0 commit comments