shuf: Use rustc-hash for performance

This commit is contained in:
oech3
2026-02-02 15:11:12 +09:00
parent 61da637d59
commit f856a46425
3 changed files with 5 additions and 1 deletions
Generated
+1
View File
@@ -4075,6 +4075,7 @@ dependencies = [
"rand 0.9.2",
"rand_chacha 0.9.0",
"rand_core 0.9.5",
"rustc-hash",
"sha3",
"uucore",
]
+1
View File
@@ -26,6 +26,7 @@ rand_core = { workspace = true }
sha3 = { workspace = true }
uucore = { workspace = true }
fluent = { workspace = true }
rustc-hash = "2.1.1"
[[bin]]
name = "shuf"
+3 -1
View File
@@ -1,4 +1,6 @@
use std::collections::HashMap;
// hijack HashMap for performance
type HashMap<K, V> = std::collections::HashMap<K, V, rustc_hash::FxBuildHasher>;
use std::ops::RangeInclusive;
use uucore::error::UResult;