@@ -164,7 +164,7 @@ final class HashMap[K, +V] private[immutable] (private[immutable] val rootNode:
164164 newHashMapOrThis(rootNode.removed(key, keyUnimprovedHash, improve(keyUnimprovedHash), 0 ))
165165 }
166166
167- override def concat [V1 >: V ](that : scala.IterableOnce [(K , V1 )]^ ): HashMap [K , V1 ] = that match {
167+ override def concat [V1 >: V ](that : scala.IterableOnce [(K , V1 )]^ ): HashMap [K , V1 ] = ( that : @ unchecked) match {
168168 case hm : HashMap [K , V1 ] =>
169169 if (isEmpty) hm
170170 else {
@@ -242,7 +242,7 @@ final class HashMap[K, +V] private[immutable] (private[immutable] val rootNode:
242242 }
243243 }
244244 }
245- that match {
245+ ( that : @ unchecked) match {
246246 case thatMap : Map [K , V1 ] =>
247247 if (thatMap.isEmpty) this
248248 else {
@@ -391,7 +391,7 @@ final class HashMap[K, +V] private[immutable] (private[immutable] val rootNode:
391391 if (isEmpty) {
392392 this
393393 } else {
394- keys match {
394+ ( keys : @ unchecked) match {
395395 case hashSet : HashSet [K ] =>
396396 if (hashSet.isEmpty) {
397397 this
@@ -2207,7 +2207,7 @@ object HashMap extends MapFactory[HashMap] {
22072207 EmptyMap .asInstanceOf [HashMap [K , V ]]
22082208
22092209 def from [K , V ](source : collection.IterableOnce [(K , V )]^ ): HashMap [K , V ] =
2210- source match {
2210+ ( source : @ unchecked) match {
22112211 case hs : HashMap [K , V ] => hs
22122212 case _ => (newBuilder[K , V ] ++= source).result()
22132213 }
@@ -2373,7 +2373,7 @@ private[immutable] final class HashMapBuilder[K, V] extends ReusableBuilder[(K,
23732373
23742374 override def addAll (xs : IterableOnce [(K , V )]^ ): this .type = {
23752375 ensureUnaliased()
2376- xs match {
2376+ ( xs : @ unchecked) match {
23772377 case hm : HashMap [K , V ] =>
23782378 new ChampBaseIterator [(K , V ), MapNode [K , V ]](hm.rootNode) {
23792379 while (hasNext) {
0 commit comments