generated from mingliqiye/lib-tem
fix(collection): 抑制类型转换警告并更新文件时间戳修复了 Collection.kt 文件中的类型转换警告问题,通过添加 @Suppress("UNCHECKED_CAST")
注解来抑制编译器警告。同时更新了文件的最后修改时
This commit is contained in:
parent
075dc2346a
commit
578f0a3e89
@ -16,7 +16,7 @@
|
|||||||
* ProjectName mingli-utils
|
* ProjectName mingli-utils
|
||||||
* ModuleName mingli-utils.main
|
* ModuleName mingli-utils.main
|
||||||
* CurrentFile Collection.kt
|
* CurrentFile Collection.kt
|
||||||
* LastUpdate 2025-09-20 14:01:07
|
* LastUpdate 2025-09-20 14:03:46
|
||||||
* UpdateUser MingLiPro
|
* UpdateUser MingLiPro
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@ -47,6 +47,7 @@ inline fun <reified T> Collection<T>.toArray(): Array<T> {
|
|||||||
* @param v 用于生成映射值的函数
|
* @param v 用于生成映射值的函数
|
||||||
* @return 转换后的 Map
|
* @return 转换后的 Map
|
||||||
*/
|
*/
|
||||||
|
@Suppress("UNCHECKED_CAST")
|
||||||
inline fun <reified T, V> Collection<T>.toMap(noinline v: (T) -> V): Map<T, V> {
|
inline fun <reified T, V> Collection<T>.toMap(noinline v: (T) -> V): Map<T, V> {
|
||||||
return this.stream().collect(
|
return this.stream().collect(
|
||||||
SuperStream.toMap(
|
SuperStream.toMap(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user