Browse Source

Use K:Int instead of just Int for Map.toIntMap so concrete IntMap class is used instead of IMap<Int,V> (see #3777)

Dan Korostelev 10 năm trước cách đây
mục cha
commit
3fd4600561
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      std/Map.hx

+ 1 - 1
std/Map.hx

@@ -138,7 +138,7 @@ abstract Map<K,V>(IMap<K,V> ) {
 		return new StringMap<V>();
 		return new StringMap<V>();
 	}
 	}
 
 
-	@:to static inline function toIntMap<V>(t:IMap<Int,V>):IntMap<V> {
+	@:to static inline function toIntMap<K:Int,V>(t:IMap<K,V>):IntMap<V> {
 		return new IntMap<V>();
 		return new IntMap<V>();
 	}
 	}