Skip to content

Commit cf80696

Browse files
committed
perf: move to interned string and construct the graph with usize
1 parent efa1aa7 commit cf80696

File tree

5 files changed

+145
-137
lines changed

5 files changed

+145
-137
lines changed

Cargo.lock

Lines changed: 11 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# coreutils (uutils)
22
# * see the repository LICENSE, README, and CONTRIBUTING files for more information
33

4-
# spell-checker:ignore (libs) bigdecimal datetime serde bincode gethostid kqueue libselinux mangen memmap uuhelp startswith constness expl unnested logind cfgs
4+
# spell-checker:ignore (libs) bigdecimal datetime serde bincode gethostid kqueue libselinux mangen memmap uuhelp startswith constness expl unnested logind cfgs indexmap
55

66
[package]
77
name = "coreutils"
@@ -374,6 +374,7 @@ time = { version = "0.3.36" }
374374
unicode-width = "0.2.0"
375375
unit-prefix = "0.5"
376376
utmp-classic = "0.1.6"
377+
indexmap = '2.12.1'
377378
uutils_term_grid = "0.7"
378379
walkdir = "2.5"
379380
winapi-util = "0.1.8"
@@ -521,6 +522,7 @@ who = { optional = true, version = "0.5.0", package = "uu_who", path = "src/uu/w
521522
whoami = { optional = true, version = "0.5.0", package = "uu_whoami", path = "src/uu/whoami" }
522523
yes = { optional = true, version = "0.5.0", package = "uu_yes", path = "src/uu/yes" }
523524

525+
524526
# this breaks clippy linting with: "tests/by-util/test_factor_benches.rs: No such file or directory (os error 2)"
525527
# factor_benches = { optional = true, version = "0.0.0", package = "uu_factor_benches", path = "tests/benches/factor" }
526528

@@ -543,6 +545,7 @@ sha1 = { workspace = true, features = ["std"] }
543545
tempfile.workspace = true
544546
time = { workspace = true, features = ["local-offset"] }
545547
unindent = "0.2.3"
548+
indexmap.workspace = true
546549
uutests.workspace = true
547550
uucore = { workspace = true, features = [
548551
"mode",

deny.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,8 @@ skip = [
8989
{ name = "itertools", version = "0.13.0" },
9090
# ordered-multimap
9191
{ name = "hashbrown", version = "0.14.5" },
92+
# indexmap
93+
{ name = "hashbrown", version = "0.16.1" },
9294
# cexpr (via bindgen)
9395
{ name = "nom", version = "7.1.3" },
9496
# const-random-macro, rand_core

src/uu/tsort/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# spell-checker:ignore (libs) indexmap
12
[package]
23
name = "uu_tsort"
34
description = "tsort ~ (uutils) topologically sort input (partially ordered) pairs"
@@ -22,7 +23,7 @@ clap = { workspace = true }
2223
thiserror = { workspace = true }
2324
uucore = { workspace = true }
2425
fluent = { workspace = true }
25-
26+
indexmap = { workspace = true }
2627
[[bin]]
2728
name = "tsort"
2829
path = "src/main.rs"

0 commit comments

Comments
 (0)